Our app fails to scale sufficiently and I'd traced our problems to eager
loading of all OneToOne relations when any single one is accessed. I would like
to fix that but wanted to get feedback first. I'm referring to Hibernate Core
3.3.1.GA below:
Currently in AbstractFieldInterceptor.intercept(
Per Hibernate Core docs, accessing a lazy property on a bytecode-instrumented
Entity returns an unproxied target property. From what I can tell, however, in
the case where the target property is an Entity as well, this is implemented by
(in hibernate 3.3.1.GA):
-generating a proxy for target ent
Naturally, things are a bit more involved:
-replaced AbstractFieldInterceptor.initializing with a Set tracking that state
on a per-fieldName basis.
That wasn't enough - TestLazyExecutable is failing - returning a null value -
it almost seems as though the same FilterInterceptor instance is reuse