Skip to content

Commit 832a057

Browse files
authored
Minor tweaks
1 parent 0ec35ce commit 832a057

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

components/messenger.rst

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -89,10 +89,11 @@ that will do the required processing for your message::
8989
Envelope
9090
--------
9191

92-
The notion of an envelope is a concept that helps us to add some context around the
93-
messages. An envelope is a message and a set of items. On a user perspective, this
94-
allows to set some configuration around the message. For example the serialization
95-
groups used when the message goes through the transport layer::
92+
The notion of an envelope is a concept that helps add context around the
93+
messages. An envelope is a message and a set of data. From a user's perspective, this
94+
allows you to set some configuration around the message. For example, to set the serialization
95+
groups used when the message goes through the transport layer, wrap your message
96+
in an ``Envelope`` and add some ``SerializerConfiguration``::
9697

9798
use Symfony\Component\Messenger\Envelope;
9899
use Symfony\Component\Messenger\Transport\Serialization\SerializerConfiguration;
@@ -103,9 +104,9 @@ groups used when the message goes through the transport layer::
103104
]))
104105
);
105106

106-
Instead of dealing directly with the messages in the handlers and middleware you
107-
can receive the envelope by implementing the ``EnvelopeAwareInterface`` marker
108-
interface on your middleware or handler like this::
107+
Instead of dealing directly with the message in the handlers or middleware, you
108+
can receive the envelope by implementing the ``EnvelopeAwareInterface`` marker,
109+
like this::
109110

110111
use Symfony\Component\Messenger\Middleware\MiddlewareInterface;
111112
use Symfony\Component\Messenger\EnvelopeAwareInterface;

0 commit comments

Comments
 (0)