Skip to content

Commit 1d04b4f

Browse files
authored
Skip internal logging in compat check (#123940)
The stable API compatibility checks ensure public jars don't change their APIs in incompatible ways. Yet the logging jar has an internal package which can change arbitrarily. This commit adds a temporary workaround to skip the internal logging package until the compat check can be made to look at module-info.
1 parent 796cfce commit 1d04b4f

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/JarApiComparisonTask.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,11 @@ private String getPath() {
111111
List<String> classNames() throws IOException {
112112
Pattern classEnding = Pattern.compile(".*\\.class$");
113113
try (JarFile jf = new JarFile(this.path)) {
114-
return jf.stream().map(ZipEntry::getName).filter(classEnding.asMatchPredicate()).collect(Collectors.toList());
114+
return jf.stream()
115+
.map(ZipEntry::getName)
116+
.filter(classEnding.asMatchPredicate())
117+
.filter(c -> c.startsWith("org/elasticsearch/logging/internal/") == false)
118+
.collect(Collectors.toList());
115119
}
116120
}
117121

0 commit comments

Comments
 (0)