On a legacy project @Entity are used as DTOs and exported to the client through ejb remoting with wildfly. Lazy properties that are not used by the client are not initialized (and not being used a LazyInitializationException is not thrown) Everything worked until 6.1. Since 6.2 a change has been introduced in SerializableProxy.java where a sessionFactory is required in the readResolve, which is not used on the client side. How can I now deserialize entities with uninitialized proxies without having to change all the server-side code? Commit that change the old functioning The global BytecodeProvider instance was removed as part of [ HHH-16058 Closed - Hibernate JIRA 2|https://hibernate.atlassian.net/browse/HHH-16058] on purpose by @Sanne Grivovero. Possible solution Introduce some sort of config property to allow using a global BytecodeProvider for this use case. |