-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Symfony Messenger component documentation #9437
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
Changes from 1 commit
585491d
b40bc71
b26de80
88ba8fe
5c828e4
31a56ee
2493c90
bcfae23
25c0b6e
a15752b
fb88abc
509e149
3fb973c
32403ea
c5306b8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
::
to display as code blocks
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,7 +46,7 @@ following middlewares are configured for you: | |
#. ``SendMessageMiddleware`` (enables asynchronous processing) | ||
#. ``HandleMessageMiddleware`` (calls the registered handle) | ||
|
||
Example: | ||
Example:: | ||
|
||
use App\Message\MyMessage; | ||
use Symfony\Component\Messenger\MessageBus; | ||
|
@@ -67,7 +67,7 @@ Handlers | |
Once dispatched to the bus, messages will be handled by a "message handler". A | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "dispatched" is confusing here: according to the Bus section, the bus is responsible for dispatching messages; and the method used to get a message on to the bus is There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. No, it's |
||
message handler is a PHP callable (i.e. a function or an instance of a class) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. we could add a link to the official doc here:
|
||
that will do the required processing for your message. It _might_ return a | ||
result: | ||
result:: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
What happens if it does or does not return a result? Does the following example code illustrate something about this statement? |
||
|
||
namespace App\MessageHandler; | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure how it even ended like that 😂 Changed!