Hi Ross,
Thanks for answering. Yes I read this documentation but it doesn't address the how-to in my opinion. Basically my question is the following:
- say I have a class MyCoolObject
- I want to persist MyCoolObject in a MongoDB collection
- what are the pieces that I have to implement to leverage the new Codec infrastructure and how do I wire it all
The 2 (similar) implementations that I have found so far seem incorrect to me because they write a custom codec which wraps their own instance of a DocumentCodec. So yes, using the documentation you pointed me at, I can "fix" their code to avoid doing that. Basically write a CodecProvider so it has access to the CodecRegistry and use that to retrieve the DocumentCodec at some point or another. But I was interested to see if there was already a "preferred" approach to do this rather than me trying to figure it all out by myself.
I hope this clarifies my question