Skip to content

Commit 19b7468

Browse files
Fix Java 17 compilation errors in OpenApiSpecGenerator
- Line 950: isSystemService() takes AxisService, not String — pass the service object instead of svcName - Line 1002: SLF4J debug(String, int) resolves to debug(String, Throwable) under Java 17 — use string concatenation instead These errors caused the GitHub Actions Site job to fail. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent ef24536 commit 19b7468

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

modules/openapi/src/main/java/org/apache/axis2/openapi/OpenApiSpecGenerator.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -947,7 +947,7 @@ public String generateMcpResourcesJson(HttpServletRequest request) {
947947
java.util.Map<String, AxisService> services = axisConfig.getServices();
948948
for (AxisService service : services.values()) {
949949
String svcName = service.getName();
950-
if (isSystemService(svcName)) continue;
950+
if (isSystemService(service)) continue;
951951

952952
// URI: logical identifier for the resource in the MCP protocol.
953953
// Uses the "axis2://" scheme so clients can distinguish these
@@ -999,7 +999,7 @@ public String generateMcpResourcesJson(HttpServletRequest request) {
999999
metadata.put("requiresAuth", requiresAuth);
10001000
}
10011001

1002-
log.debug("Generated MCP resources JSON ({} services)", resources.size());
1002+
log.debug("Generated MCP resources JSON (" + resources.size() + " services)");
10031003
return jackson.writeValueAsString(root);
10041004

10051005
} catch (Exception e) {

0 commit comments

Comments
 (0)