Given an entity class
@Entity // could be @Embeddable etc.
@Access(AccessType.PROPERTY)
class Foo {
String bar;
void setBar(String bar) { … }
}
This type is usable in standard Hibernate, as the package-protected setBar(…) will be available to Hibernate. In a native image, that method is not available as PersistenceManagedTypesBeanRegistrationAotProcessor calls BindingReflectionHintsRegistrar.registerReflectionHints(…) which only considers public methods.
Given an entity class
This type is usable in standard Hibernate, as the package-protected
setBar(…)will be available to Hibernate. In a native image, that method is not available asPersistenceManagedTypesBeanRegistrationAotProcessorcallsBindingReflectionHintsRegistrar.registerReflectionHints(…)which only considers public methods.