fix(core, gateway): route unknown tools to tool-other and match baseName for hidden tools
This commit is contained in:
@@ -51,7 +51,7 @@ public class ExecuteService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Dynamic Routing: Find the target Pod from the Redis registry
|
// Dynamic Routing: Find the target Pod from the Redis registry
|
||||||
String targetUrl = "http://localhost:8082"; // Fallback
|
String targetUrl = "http://localhost:8084"; // Fallback (tool-other)
|
||||||
if (plan.getPodUrl() != null && !plan.getPodUrl().isEmpty()) {
|
if (plan.getPodUrl() != null && !plan.getPodUrl().isEmpty()) {
|
||||||
targetUrl = plan.getPodUrl();
|
targetUrl = plan.getPodUrl();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ public class BusinessToolController {
|
|||||||
? mcpProperties.getNamespace() + "_" + baseName
|
? mcpProperties.getNamespace() + "_" + baseName
|
||||||
: baseName;
|
: baseName;
|
||||||
|
|
||||||
if (expectedName.equals(functionName)) {
|
if (expectedName.equals(functionName) || baseName.equals(functionName)) {
|
||||||
targetBean = bean;
|
targetBean = bean;
|
||||||
targetMethod = method;
|
targetMethod = method;
|
||||||
targetFunctionAnnotation = mcpFunc;
|
targetFunctionAnnotation = mcpFunc;
|
||||||
|
|||||||
Reference in New Issue
Block a user