3

Idea is simple - I have common code base, I want to extend some entities with additional fields for particular clients, but remain all relationships working, ie. without need to update related objects.

Exactly what I need is provided with EclipseLink - Eclipse Link Extensible Entities with @VirtualAccessMethods. Hibernate can achieve similar thing by using Map instead of entity bean, so by configuring hibernate XML I can achieve similar thing.

I could not find anything similar in JPA. Is it possible to do it with JPA?

This question is very similar to questions already here, but they are rather old and defined less specific than this one, but I guess answer to this is also answer to them. Answers accepted there are not what I need :

spring + JPA: “Extend” entity classes at load-time from configuration

JPA and database Flex fields

Community
  • 1
  • 1
dejanmr
  • 47
  • 2
  • 8

0 Answers0