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

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

configurationsection - activeMq-5.13.3 setup configurations for wildfly 10.0.0 -