Per class @DbJsonB

14 views
Skip to first unread message

Iliya Ivanov

unread,
Apr 8, 2023, 10:26:47 AM4/8/23
to Ebean ORM
Hi all,

I have a POJO class, that I want to be (de-)serialized from/to postgreslq jsonb.
I know that if i annotate all fields of this type with @DbJsonB it is working perfectly.

Is there any other options that I can use, so all fields than are instances of the POJO, to be serialized as jsonb? For example allow @DBJsonB to be available also for classes.

I know i can use @Embeddable / @Embedded, or I can make it as an Entity and use standard relational approach, but this is not acceptable for my case.

Rob Bygrave

unread,
Apr 10, 2023, 5:56:10 AM4/10/23
to eb...@googlegroups.com
> Is there any other options that I can use, so all fields than are instances of the POJO, to be serialized as jsonb? For example allow @DBJsonB to be available also for classes.

No, there is currently no other option - we need to annotate the fields with @DbJsonB.


--

---
You received this message because you are subscribed to the Google Groups "Ebean ORM" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ebean+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ebean/757fff10-9d96-459d-b00f-9c5684303262n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages