JaVers objects should be Jackson friendly #205
Comments
today I'll release javers 1.3.9, int this version Still, JSON output created by Jackson will be very verbose as it simply uses Jackson defaults. |
Sounds good. I'll stay tuned and let you know how things go. |
check fresh 1.3.9 release |
Works perfect! Using the following code JSON-output is nice and smooth:
BTW, how can I influence how changes on references are rendered in "left" and "right" properties? Does it eventually work with Spring data-projections? |
well, since you are not using JaVavers to build JSON, it's rather a question to spring-mcv or jackson, That's why I recommend using Javers to building JSON. JaVers creates neat, concise and customizable JSON. In Spring controller you can do it quite easily:
|
What I meant was adjusting the following output through e.g. a
Is it possible to retrieve the name of the LocationNetwork object and place it inside the "left"-property as a string? |
... did the following:
... which works when I change a property only (of course as the upper comparator is not involved) or change a reference only. But when I do both in combination it comes to an error when the name of the reference (network) is resolved. In this case leftNetwork and rightNetwork are bot null. |
OK, got it now. It is important that the comparator code is written the following way when the third situation occurs:
|
Ok, good to hear that CustomComparators works for you |
You can close this issue if you want to. |
Serialize JaVers changes
List<Change>
through Jackson. SnapshotsList<CdoSnapshot>
already work.The text was updated successfully, but these errors were encountered: