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

MapLike serialized incorrectly #15

Closed
wajda opened this issue Jan 4, 2021 · 4 comments · Fixed by #19
Closed

MapLike serialized incorrectly #15

wajda opened this issue Jan 4, 2021 · 4 comments · Fixed by #19
Assignees

Comments

@wajda
Copy link
Contributor

wajda commented Jan 4, 2021

Maps obtained by calling Map.mapValues(...) or Map.filterKeys(...) etc serialized as plain objects ({f: {}} and {p: {}} respectively)

@wajda
Copy link
Contributor Author

wajda commented Jan 4, 2021

I'm working on the fix, will send a PR shortly

@wajda
Copy link
Contributor Author

wajda commented Jan 4, 2021

I'm going to fix it by registering a serializer for more concrete Map impl classes, simply because it's how it's done and it's easy.
But generally speaking it's not a future proof solution. A concrete serializer should be looked up recursively starting from this.getClass and moving up the object hierarchy. Yet not sure if it can be done on top of the existing velocypack code base without making to much changes.

wajda added a commit to wajda/java-velocypack-module-scala that referenced this issue Jan 4, 2021
@rashtao rashtao self-assigned this Jan 19, 2021
@rashtao
Copy link
Contributor

rashtao commented Feb 10, 2021

Hi @wajda ,
thanks for reporting and contributing.

From what I can see, there are many cases uncovered by this library, either related to different Scala versions or specific Scala types, which require a lot of effort to implement, maintain and further develop (eg. with regards to Scala 3).

On the other side, jackson-dataformat-velocypack reached version 1.0.0 and can be configured with Jackson Scala language module which comes with full support for Scala 2.11 and 2.12 and 2.13 (and plans to support Scala 3).

Therefore I would like to deprecate this library and invite you to migrate your projects to jackson-dataformat-velocypack.

@wajda
Copy link
Contributor Author

wajda commented Feb 19, 2021

Thanks, I will take a look.
But even being deprecated this library still does its job great for majority of use cases, so if you don't mind it would be great to finish this fix especially having the code prepared already. Thank you!

wajda added a commit to wajda/java-velocypack-module-scala that referenced this issue Feb 19, 2021
wajda added a commit to wajda/java-velocypack-module-scala that referenced this issue Feb 19, 2021
wajda added a commit to wajda/java-velocypack-module-scala that referenced this issue Feb 19, 2021
wajda added a commit to wajda/java-velocypack-module-scala that referenced this issue Feb 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants