Lots of great ideas there. Some covered by the new bytecode work. The
"model metadata" stuff I think is another piece to his bytecode
enhancement; we could consider doing the same in our enhancement; it is
very similar in fact to what we do with the JPA metamodel generator and
populating that at runtime (iiuc).
I really have to look at the collection stuff; that sounds very
interesting. I had not heard of those libraries before.
Might be worthwhile to reach out to them to see if they'd like to see any
of this in Hibernate proper.
On Thu, Oct 22, 2015, 7:38 AM Davide D'Alto <davide(a)hibernate.org> wrote:
Hi all,
I just want to mention that
a user on the Hibernate forum created a framework on top of Hibernate:
https://forum.hibernate.org/viewtopic.php?f=1&t=1042072
https://github.com/babyfish-ct/babyfish
The main concept is around the use of an ObjectModel that replaces the
proxies and contains all the metadata to access the entities.
Here an example on how to define an object model in Java:
https://github.com/babyfish-ct/babyfish/blob/master/demo/babyfishdemo-om4...
In JPA, the object model is generated during compile time and can be
accessed using:
private JPAObjectModelMetadata employeeOMM =
JPAMetadatas.of(Company.class);
The ObjectModel provides a fluent API to get lazy associations,
disable/enable update on properties and so on.
Cheers,
Davide
_______________________________________________
hibernate-dev mailing list
hibernate-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/hibernate-dev