java - hibernate extend more entities with a single metadata table -
i have entities in java web project, each entity defined in specific table. due continuos customizations required on entities model,
i've decided create 1 metadata entity , table save additional attributes of existing entities, follows: id, entitytype, entityid, metakey, metavalue
i'd use metadata entity extend dynamically entities need additional key/value attributes, referencing uniquely entity entityname , entityid.
is there smart way to that? right now, everytime need store additional key/value entity, call specific method on metadatadao add key/value, , retrieve once load entity data, i'd need smarter way manage storing/reading/attaching metas entity.
hope question clear. best regards
Comments
Post a Comment