Skip to content
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

Create Version Tolerant Serializer Sample + Update Serialization Docs #5492

Open
JorgeCandeias opened this issue Mar 31, 2019 · 2 comments
Open
Assignees
Milestone

Comments

@JorgeCandeias
Copy link
Contributor

JorgeCandeias commented Mar 31, 2019

Questions about broken state due to version mismatch seem to pop up again and again. I've clashed against that too, wasn't the first, won't be the last. Would be nice to get the docs updated and some samples working for Bond and Protobuf at least, as to have somewhere to point people at. Putting it here in case someone wants a go at it. Otherwise I'll get to this at some point.

@sergeybykov sergeybykov added this to the Triage milestone Apr 1, 2019
@veikkoeeva
Copy link
Contributor

veikkoeeva commented Apr 11, 2019

Related documentation issue at #4771. There are also a few other related issues one might want to document more carefully at #1998 (I'm not sure if it's all relevant currently) and #2483 and #2153 since the same question.

There's a bit of an example from pre-2.n era (before DI) that it should be possible to a custom transformation step besides having a version tolerant serializer too. ADO.NET has one test for switching from binary to XML, but it could also be just a piece of handwritten code. It relies on having a canonical interface for (de)serializing and one example being OrleansStorageDefaultJsonDeserializer (more here).

The (de)serializer is picked like at

public SerializationChoice PickDeserializer(string serviceId, string storageProviderInstanceName, string grainType, GrainReference grainReference, IGrainState grainState, string tag = null)
. As seen, it has all the information available, including grain state, to make the decision. It could also do a transformation.

I have been thinking if there'd be a way to unify this idea of picking (de)serializers by whatever data available throughout Orleans. This way one could, say, potentially save on (de)serialization time and stream data via WebAPI straight to data storage (with cancellation support).

@ghost
Copy link

ghost commented Jul 28, 2022

We've moved this issue to the Backlog. This means that it is not going to be worked on for the coming release. We review items in the backlog at the end of each milestone/release and depending on the team's priority we may reconsider this issue for the following milestone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants