Symfony News

New in Symfony 6.1: Serializer Profiling

Mathias Arlaud

Contributed by
Mathias Arlaud
in #45656.

The Symfony Serializer component design is based on the chain-of-responsibility pattern. That makes it hard to know which normalizers and encoders are used during the entire (de)serialization process.

That's why in Symfony 6.1 we've added a new Serializer panel in the Symfony Profiler:

Serializer profiler panel in Symfony 6.1

This feature decorates the serializer service to trace the activity of the serialize(), deserialize(), normalize(), denormalize(), encode() and decode() methods calls. All normalizers and encoders are decorated as well, so you'll get the full details and total duration of all (de)serialization steps.

You don't need to add or configure anything to enjoy this feature. Just update your project to Symfony 6.1 and you'll get the new debugging information in the Symfony profiler.


Sponsor the Symfony project.


About us

What a Symfony developer should know about the framework: News, Jobs, Tweets, Events, Videos,...

Resources

Find us on Twitter

Find us on Facebook