fix: remove internal API fields from _meta to match YAML strictly
Some checks failed
Deploy to OCIWP / deploy (push) Failing after 27s

This commit is contained in:
jade
2026-08-13 18:22:43 +09:00
parent 33e1261b38
commit 376edbbcfb
2 changed files with 6 additions and 19 deletions

View File

@@ -181,29 +181,15 @@ public class McpRouterController {
toolMap.put("annotations", annotations);
Map<String, Object> meta = new HashMap<>();
meta.put("uid", t.getUid());
meta.put("version", t.getSemver());
meta.put("moduleName", t.getModuleName());
meta.put("category_key", t.getCategoryKey());
meta.put("tags", t.getTags());
meta.put("owner_org", t.getOwnerOrg());
meta.put("legacy_interface_id", t.getMciServiceId());
meta.put("display_description", t.getDisplayDescription());
meta.put("example_queries", t.getExampleQueries());
meta.put("example_queries", t.getExampleQueries());
meta.put("required_env_keys", t.getRequiredEnvKeys());
meta.put("endpoint", t.getEndpoint());
meta.put("podUrl", t.getPodUrl());
meta.put("visible", t.getVisible());
meta.put("enabled", t.getEnabled());
meta.put("isRegistered", t.getIsRegistered());
meta.put("requiresApproval", t.getRequiresApproval());
meta.put("integrationType", t.getIntegrationType());
meta.put("mciServiceId", t.getMciServiceId());
meta.put("operationType", t.getOperationType());
meta.put("retryEnabled", t.getRetryEnabled());
meta.put("circuitBreakerFailureThreshold", t.getCircuitBreakerFailureThreshold());
meta.put("circuitBreakerOpenMillis", t.getCircuitBreakerOpenMillis());
meta.put("timeoutMillis", t.getTimeoutMillis());
toolMap.put("_meta", meta);
return toolMap;

View File

@@ -297,8 +297,9 @@
t._latency = 0;
t._responseData = null;
categories.add(t._meta?.category_key || 'oth');
if (t._meta?.moduleName) {
modules.add(t._meta.moduleName.replace('dap-was-', ''));
const modName = t.name ? t.name.split('_')[0].replace('dap-was-', '') : '';
if (modName) {
modules.add(modName);
}
});
@@ -358,7 +359,7 @@
filteredTools = allTools.filter(t => {
const matchSearch = t.name.toLowerCase().includes(search) || (t.description || '').toLowerCase().includes(search);
const matchCategory = !category || (t._meta?.category_key || 'oth') === category;
const toolMod = t._meta?.moduleName ? t._meta.moduleName.replace('dap-was-', '') : '';
const toolMod = t.name ? t.name.split('_')[0].replace('dap-was-', '') : '';
const matchModule = !moduleFlt || toolMod === moduleFlt;
return matchSearch && matchCategory && matchModule;
});
@@ -395,7 +396,7 @@
html += `
<tr id="row-${index}">
<td><span class="cat-badge" style="background:rgba(59,130,246,0.1); color:#60a5fa; border:1px solid rgba(59,130,246,0.2);">${tool._meta?.moduleName ? tool._meta.moduleName.replace('dap-was-', '') : 'unknown'}</span></td>
<td><span class="cat-badge" style="background:rgba(59,130,246,0.1); color:#60a5fa; border:1px solid rgba(59,130,246,0.2);">${tool.name ? tool.name.split('_')[0].replace('dap-was-', '') : 'unknown'}</span></td>
<td><span class="cat-badge">${tool._meta?.category_key || 'oth'}</span></td>
<td class="font-medium text-slate-200">${tool.name}</td>
<td class="text-sm text-zinc-400 geist-mono flex items-center gap-3">