symfony/symfony

[Cache] Symfony Serializer implementation for MarshallerInterface

javaDeveloperKid opened this issue · 2 comments

Description

I'm surprised there is no built-in integration for Cache Component with Serializer Component as the implementation of MarshallerInterface.

Example

No response

Please give more insights about what a possible implementation would look like and more importantly what benefits it would bring.

IIUC Marshaller is just a serializer but another name was chosen not to create second SerializerInterface class in Symfony ecosystem. JSON string is a type of serializer string so one may want to store the cached value as a json (e.g. cache as json and return cached jsonstring directly from API). Integration with Serializer Component would allow that.