-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[Serializer] Serialization versioning #38478
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 7.3
Are you sure you want to change the base?
[Serializer] Serialization versioning #38478
Conversation
Old PR => #35617 |
@dunglas I would love to get your input here whenever you have time. |
@@ -934,6 +934,7 @@ private function addSerializerSection(ArrayNodeDefinition $rootNode) | |||
->end() | |||
->end() | |||
->end() | |||
->scalarNode('default_version')->end() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From #38542 serializer.default_context
config option is avalable now.
Why not use serializer.default_context.version
instead?
I have made some updates to this PR.
You can find it here: |
Thank for your work @connorhu ! |
use Symfony\Component\Serializer\Exception\InvalidArgumentException; | ||
|
||
/** | ||
* Annotation class for @Since(). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if you're still maintaining this PR, but this probably needs to be changed into an attribute now.
Add Serialization versioning.
@Since
annotation@Until
annotationsince
anduntil
to thexml
andyaml
mappingversion
context optionserializer.default_version
in the framework config