Well, I guess WeakReference is one option as mentioned above. Dyorgio your SqlTypeDescriptorRegistry workaround would just need to re-register the default SqlTypeDescriptor for that code. Yes this would potentially affect other SessionFactories due to "bleed through" I mentioned |