Skip to content

Commit afaaf3d

Browse files
committed
Ignore server locations whose representative class isn't loaded
1 parent 3248fd2 commit afaaf3d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

test/framework/src/main/java/org/elasticsearch/bootstrap/TestScopeResolver.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,8 @@ public static Function<Class<?>, PolicyManager.PolicyScope> createScopeResolver(
6464
for (var location : serverBuildInfo.locations()) {
6565
var classUrl = TestScopeResolver.class.getClassLoader().getResource(location.representativeClass());
6666
if (classUrl == null) {
67-
throw new IllegalArgumentException("Cannot locate class [" + location.representativeClass() + "]");
67+
logger.debug("Representative class is unavailable; proceeding without {}", location);
68+
continue;
6869
}
6970
try {
7071
scopeMap.put(getCodeSource(classUrl, location.representativeClass()), PolicyManager.PolicyScope.server(location.module()));

0 commit comments

Comments
 (0)