hibernate/hibernate-orm · error · HibernateException
Using the ReflectionOptimizer is not possible when the confi
Error message
Using the ReflectionOptimizer is not possible when the configured BytecodeProvider is 'none'. Use a different BytecodeProvider
What it means
Error "Using the ReflectionOptimizer is not possible when the configured BytecodeProvider is 'none'. Use a different BytecodeProvider" thrown in hibernate/hibernate-orm.
Source
Thrown at hibernate-core/src/main/java/org/hibernate/bytecode/internal/none/BytecodeProviderImpl.java:44
*
* @since 5.4
*/
public final class BytecodeProviderImpl implements BytecodeProvider {
@Nonnull
@Override
public ProxyFactoryFactory getProxyFactoryFactory() {
return new NoProxyFactoryFactory();
}
@Override
@Nonnull
public ReflectionOptimizer getReflectionOptimizer(
@Nonnull Class<?> clazz,
@Nonnull String[] getterNames,
@Nonnull String[] setterNames,
@Nonnull Class<?>[] types) {
throw new HibernateException( "Using the ReflectionOptimizer is not possible when the configured BytecodeProvider is 'none'. Use a different BytecodeProvider" );
}
@Override
public @Nullable ReflectionOptimizer getReflectionOptimizer(@Nonnull Class<?> clazz, @Nonnull Map<String, PropertyAccess> propertyAccessMap) {
return null;
}
@Override
public @Nullable Enhancer getEnhancer(@Nonnull EnhancementContext enhancementContext) {
return null;
}
}
View on GitHub (pinned to fad1729dce)
Solutions
- Remove the hibernate.bytecode.provider=none setting (or set it to bytebuddy) so proxies/reflection optimization can be generated, or avoid features requiring proxies.
Example fix
Remove the hibernate.bytecode.provider=none setting (or set it to bytebuddy) so proxies/reflection optimization can be generated, or avoid features requiring proxies.
When it happens
Trigger: Bytecode enhancement, proxy creation, or lazy interception is applied to an incompatible class or configuration.
Common situations: Build-time enhancement with module-system restrictions, mismatched Hibernate versions between build and runtime, or hibernate.bytecode.provider=none with a model that needs proxies.
AI-assisted analysis of hibernate/hibernate-orm@fad1729dce (2026-08-22).
Data as JSON: /api/errors/5e63785fb14f7c87.
Report an issue: GitHub.