java - JPA\Hibernate: Persisted list of entities in Singleton -
i have singleton manages list of entities in db.
public class schedulledqueue { list<myentity> entities; }
i need store list in database. want single table contains entities singleton grab data.
table schedulled_queue ( entity_id character varying(32), constraint schedulled_queue foreign key (entity_id) references tbl_my_entity (entity_id) match simple )
is there way map singleton schedulledqueue in hibernate accomplish this? or should not bother such thing?
if have multiple schedulledqueue objects makes sense have 1 many relation between schedulledqueue , myentity.
since schedulledqueue in singleton. don't see advantage of creating entity of it.
java hibernate jpa design-patterns singleton
No comments:
Post a Comment