Skip to content

Commit 64b41f6

Browse files
committed
try api jar loader when loading a provider from the system property
Signed-off-by: Lukas Jungmann <[email protected]>
1 parent 0c7bfeb commit 64b41f6

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

api/src/main/java/jakarta/activation/FactoryFinder.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,11 @@ static <T> T find(Class<T> factoryClass,
6666
if (result != null) {
6767
return result;
6868
}
69+
// try api loader
70+
result = newInstance(className, defaultClassName, FactoryFinder.class.getClassLoader());
71+
if (result != null) {
72+
return result;
73+
}
6974
}
7075

7176
// standard services: java.util.ServiceLoader

0 commit comments

Comments
 (0)