Symfony 8.2 Adds Messenger Serializer for Cross-Application Messaging
Developers contributing to Symfony Messenger have added an interoperability serializer for the upcoming Symfony 8.2 release, allowing applications to exchange JSON messages without relying on Symfony-specific metadata. The development, detailed in an official technical announcement on 29 October 2026, is intended to simplify communication between Symfony applications and services written in other languages, including Python, Node.js and Go.
Symfony Messenger already supports communication through shared message transports, but its existing serializer includes metadata called envelope stamps. These can reference PHP classes or message buses that receiving applications do not recognise, resulting in decoding or processing errors. The new messenger.transport.interop_serializer sends messages without these stamps and ignores incoming stamps. Messages returned for retries or sent to failure transports retain the metadata needed to track retry attempts.
Cross-application communication still requires applications to agree on message formats and types. Symfony normally identifies messages using PHP class names, which may not be meaningful to services written in other languages. Developers can assign shared serialized type names or configure the serializer to determine the message type when incoming messages lack a type header. This allows applications using different technologies to interpret the same messages without sharing Symfony's PHP classes.
The release also introduces stamp header mappers to preserve selected message metadata. When the identity_stamps option is enabled, Messenger adds message identification, correlation and causation stamps, which can be exchanged through the plain headers message_id, correlation_id and causation_id. Developers can implement custom mappings for additional information, such as tenant identifiers. Nicolas Philippe contributed the interoperability serializer, while Nicolas Grekas contributed the header-mapping functionality.
Symfony 8.2 also extends message signing to include custom headers generated during serialization, excluding Content-Type. The announcement warns that Symfony 7.4.18 and later, and Symfony 8.1.6 and later, reject signed messages containing headers outside the previously permitted set. When introducing additional signed headers, developers are advised to upgrade receiving applications before sending applications to avoid compatibility problems.
For Drupal developers, the change is relevant to applications that communicate with external services through message queues. The contributed Symfony Messenger + Drupal project already provides integration for asynchronous message processing and transports. However, the interoperability serializer is not a new Drupal core feature, and its availability through Drupal integrations has not been established. Adoption will depend on compatible Symfony components and appropriate transport and message configuration.
