Does Symfony Messenger Remember Between Runs? The Transport Holds the Message. The Handler Starts Empty.
Does Symfony Messenger Remember Between Runs? The Transport Holds the Message. The Handler Starts Empty. Symfony Messenger has a precise, narrow kind of memory. It remembers a message exactly as long as the message still needs delivering, and not one moment longer. The payload you dispatched, plus the stamps attached to it, sits in a transport until a worker picks it up, handles it, and acknowledges it. Then the row is deleted, the envelope is gone, and nothing about what the handler did, found
Does Symfony Messenger Remember Between Runs? The Transport Holds the Message. The Handler Starts Empty.
Symfony Messenger has a precise, narrow kind of memory. It remembers a message exactly as long as the message still needs delivering, and not one moment longer. The payload you dispatched, plus the stamps attached to it, sits in a transport until a worker picks it up, handles it, and acknowledges it. Then the row is deleted, the envelope is gone, and nothing about what the handler did, found, or decided survives into the next message. Messenger is a delivery system with a short memory for undelivered work, not a memory system for the work itself.
What the transport actually keeps
A dispatched message becomes an envelope: the message object plus a set of stamps carrying metadata such as the transport it arrived from, the retry count, and a redelivery marker. Where that envelope waits depends on the transport you configured. With the Doctrine transport, the serialized envelope is a row in a messenger_messages table, created by messenger:setup-transports, holding the body, headers, queue name, and timestamps for creation, availability, and delivery. With the AMQP transport it waits in a RabbitMQ queue, with Redis it waits in a stream, and with the sync transport it does not wait at all: the handler runs immediately, inside the dispatching request, and nothing is stored anywhere.
That storage is real persistence. A message queued on Friday is still queued on Monday, across deploys and worker restarts, until a consumer handles it. But notice what is being persisted: the instruction, not the outcome. The envelope holds the inputs the handler will need, because you put them there at dispatch time. It never gains new content while it waits, and once the worker acknowledges it, the transport deletes it. The queue is a to-do list that erases each item as it is checked off.
The worker is built to forget
The forgetting is not an accident of the queue. It is built into the worker itself. messenger:consume runs as a long-lived process, and by default Messenger resets your services after each handled message specifically so that state from one handler cannot leak into the next one. Entity managers are cleared, accumulators are emptied, and in-memory caches attached to services are discarded. Symfony 8.1 softened this only as a performance dial: --no-reset can reset every N messages instead of every one, and the documentation frames the trade-off as speed against state leaking between handlers. Either way, the design assumption is that each message is handled by a fresh application that knows only what the envelope tells it.
Retries follow the same pattern. When a handler throws, the message goes back to the transport with a delay stamp and an incremented retry count. The default strategy allows 3 retries, starting at a 1000 ms delay with a multiplier of 2. When retries run out, a configured failure transport receives the message, where it waits for a human to inspect it with messenger:failed:show and resend it with messenger:failed:retry. The failure queue remembers that something failed, and it remembers the original payload and the exception details. It does not remember anything the handler managed to do before it failed, and a resent message starts its handler from the beginning, not from the point of failure.
Where that leaves an AI handler
Now put an AI step inside the handler, which is exactly where scheduled automation is heading: a message arrives every morning, a handler calls a model to triage, summarize, or decide, and dispatches follow-up messages from the result. Messenger gives that handler a clean, reliable delivery and a payload. Everything else is on you.
The handler cannot know what yesterday's run concluded unless yesterday's handler wrote it somewhere itself and today's handler reads it back. It cannot know that a customer was already contacted, that a report was already sent in a slightly different form, or that a decision was reversed last week, because none of that is a message anyone dispatched. Teams end up hand-building the same layer every time: a state table here, a JSON column there, a "last run summary" field that somebody has to remember to update and the next handler has to remember to read. The queue was never the problem. The missing piece is a shared past that every run reads at the start and writes to at the end, without each handler inventing its own version of it.
That is the gap Vilix AI is built to fill. Vilix AI is a cloud-hosted memory layer for AI agents that connects over MCP, the standard protocol AI tools use to reach outside data, so a handler's model call can pull in the full history of earlier runs before it acts and save its conclusions when it finishes. The memory is the full conversation history, not just extracted facts, so the reasoning behind a past decision is still there to be checked. It is the same memory across every tool and device that connects, not a table that lives inside one Symfony application. There is nothing to host or maintain, a free plan that stays free forever, a 7-day Pro trial with no card required, and your data can be exported or deleted at any time.
The honest summary
Symfony Messenger remembers delivery, not experience. The transport holds an envelope until it is handled, the failure transport holds it when handling fails, and the worker deliberately wipes service state between messages so nothing leaks across. For moving work around, that is exactly right. For an AI step that runs on a schedule and is supposed to build on its own past, the remembering has to come from a memory layer the handler connects to, because the queue, by design, forgets everything the moment the work is done.