Error due to sending the same counter ID seen while processing queue

Created on 21 May 2024, 8 months ago
Updated 12 September 2024, 4 months ago

Problem/Motivation

The following error has been seen while processing the queue.

[error]  GuzzleHttp\Exception\ServerException: Server error: `POST https://tom.vgwort.de/api/external/metis/rest/message/v1.0/newMessageRequest` resulted in a `500 Internal Server Error` response:
{"message":{"errorcode":3,"errormsg":"Privater Identifikationscode: Die Erstmeldung zu dieser ZΓ€hlmarke wurde bereits d (truncated...)
 in GuzzleHttp\Exception\RequestException::create() (line 113 of /var/www/html/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php).

Steps to reproduce

Send a newMessage request with the same counter ID as one that has already been sent.

Proposed resolution

TBD

Remaining tasks

  • Investigate to ensure that the counter ID is for the same piece of content. Different content with the same counter ID would be a serious problem.
  • Decide whether we should special case this error and add the entity to the map to indicate that it has been sent to VGWort.

User interface changes

N/a

API changes

TBD

Data model changes

TBD

πŸ› Bug report
Status

Active

Version

2.0

Component

Code

Created by

πŸ‡¬πŸ‡§United Kingdom alexpott πŸ‡ͺπŸ‡ΊπŸŒ

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @alexpott
  • πŸ‡©πŸ‡ͺGermany osopolar πŸ‡©πŸ‡ͺ GER 🌐

    In \Drupal\vgwort\Plugin\AdvancedQueue\JobType\RegistrationNotification::process() $response = $this->httpClient->send($request); is called without try-catch-block, at least while sending the message via drush vgwort:send node 1. We should interception the error there.

  • πŸ‡¬πŸ‡§United Kingdom alexpott πŸ‡ͺπŸ‡ΊπŸŒ

    Good idea for Drush... if this was the queue the error would be caught and logged... but because this is not in the queue it is not.

  • πŸ‡¬πŸ‡§United Kingdom alexpott πŸ‡ͺπŸ‡ΊπŸŒ

    The counter ID is based on the UUID. The UUID cannot be the same for different content. There is a unique key on it in the database.

  • πŸ‡©πŸ‡ͺGermany osopolar πŸ‡©πŸ‡ͺ GER 🌐

    For me the error happened on test environment after importing a fresh database dump from production. So it's not a big deal.

Production build 0.71.5 2024