-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[Messenger] Add new messenger:count
command that return a list of transports with their "to be processed" message count.
#46571
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Hey! I think @monteiro has recently worked with this code. Maybe they can help review this? Cheers! Carsonbot |
ogizanagi
approved these changes
Jun 7, 2022
src/Symfony/Component/Messenger/Command/CountMessagesCommand.php
Outdated
Show resolved
Hide resolved
ogizanagi
reviewed
Jun 7, 2022
src/Symfony/Bundle/FrameworkBundle/Resources/config/console.php
Outdated
Show resolved
Hide resolved
src/Symfony/Bundle/FrameworkBundle/Resources/config/console.php
Outdated
Show resolved
Hide resolved
cb724f9
to
b56e311
Compare
b56e311
to
60293b7
Compare
fabpot
requested changes
Jul 22, 2022
src/Symfony/Component/Messenger/Command/CountMessagesCommand.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Messenger/Command/CountMessagesCommand.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Messenger/Command/CountMessagesCommand.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Messenger/Command/CountMessagesCommand.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Messenger/Command/CountMessagesCommand.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Messenger/Command/CountMessagesCommand.php
Outdated
Show resolved
Hide resolved
fabpot
approved these changes
Aug 1, 2022
…ransports with their "to be processed" message count.
91caa27
to
e5433cd
Compare
Thank you @ktherage. |
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Why ?
I worked on a project that didn't had insights on how many messages were present in "queues" (because of some hosting quirks) and to have this information we've developed a command that aims to make it possible via the Symfony's console.
After a visio call with an ex-colleague on another Symfony project, it turns out that he was verry interested to have this command in Symfony.
I've also discused with @Jean-Beru that literraly pushed me too open that PR.
So here I am.
What does it does ?
This quite simple, like for the
setup-transport
command it takes in input all configured transports' receivers and Only if they implementSymfony\Component\Messenger\Transport\Receiver\MessageCountAwareInterface
it gets the message count and prints it out in a pretty little table.Limitation
This command won't work if the configured transport's receiver does not implement
Symfony\Component\Messenger\Transport\Receiver\MessageCountAwareInterface
A small demo ?
2022-06-03-12-50-58.mp4