-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MessageQueue MessageController returns incomplete lock object, failed messages are not requeued #34754
Comments
Hi @PTuijtelaars-ISAAC. Thank you for your report.
Make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, Add a comment to the issue:
For more details, review the Magento Contributor Assistant documentation. Add a comment to assign the issue: To learn more about issue processing workflow, refer to the Code Contributions.
🕙 You can find the schedule on the Magento Community Calendar page. 📞 The triage of issues happens in the queue order. If you want to speed up the delivery of your contribution, join the Community Contributions Triage session to discuss the appropriate ticket. 🎥 You can find the recording of the previous Community Contributions Triage on the Magento Youtube Channel ✏️ Feel free to post questions/proposals/feedback related to the Community Contributions Triage process to the corresponding Slack Channel |
Hi @engcom-Hotel. Thank you for working on this issue.
|
Hi @engcom-Lima. Thank you for working on this issue.
|
Hi @PTuijtelaars-ISAAC , Thanks for reporting the issue Tried reproducing the issue with latest 2.4-develop instance however the issue is not reproducible. Steps tried to reproduce the issue
Output: Pasting here different status for reference:
If the issue is still reproducible for you on latest 2.4-develop instance do let us know the exact steps so I can retry the same. Thanks |
Hi @PTuijtelaars-ISAAC , We have noticed that this issue has not been updated for a period of 14 Days. Thanks |
Preconditions (*)
Steps to reproduce (*)
Expected result (*)
Actual result (*)
The Magento\Framework\MessageQueue\MessageController is used to create the lock and return the LockInterface Object. The object does not contain all the information neccessary to handle the cleaning of the queue_lock table as is defined in Magento\Framework\MessageQueue\Consumer getTransactionCallback.
The getTransactionCallback expects that there is an id added to the lock object, but the id returned is null, therefor no locks are cleaned and affected messages end up with a status QueueManagement::MESSAGE_STATUS_COMPLETE as it is set in aknowledge method of the driver.
This can be fixed by patching the MessageController
`diff --git a/MessageController.php b/MessageController.php
index ae5fe65..05bd64d 100644
--- a/MessageController.php
+++ b/MessageController.php
@@ -66,6 +66,7 @@ public function lock(EnvelopeInterface $envelope, $consumerName)
throw new MessageLockException(new Phrase('The "%1" message code was already processed.', [$code]));
}
$this->writer->saveLock($lock);
}`
Please provide Severity assessment for the Issue as Reporter. This information will help during Confirmation and Issue triage processes.
The text was updated successfully, but these errors were encountered: