mirror of
https://github.com/hibernate/hibernate-orm
synced 2025-02-19 17:45:10 +00:00
HHH-17705 Load default bytecode provider using the correct ClassLoader
This commit is contained in:
parent
c7114ce442
commit
4508d2f3be
@ -61,7 +61,11 @@ public Class<BytecodeProvider> getServiceInitiated() {
|
||||
|
||||
@Internal
|
||||
public static BytecodeProvider buildDefaultBytecodeProvider() {
|
||||
return getBytecodeProvider( ServiceLoader.load( BytecodeProvider.class ) );
|
||||
// Use BytecodeProvider's ClassLoader to ensure we can find the service
|
||||
return getBytecodeProvider( ServiceLoader.load(
|
||||
BytecodeProvider.class,
|
||||
BytecodeProvider.class.getClassLoader()
|
||||
) );
|
||||
}
|
||||
|
||||
@Internal
|
||||
|
Loading…
x
Reference in New Issue
Block a user