apache/incubator-seata · error · ServiceCallException
MCP GET request failed with status: %s, response: %s
Error message
MCP GET request failed with status: %s, response: %s
What it means
getCallNameSpace throws ServiceCallException when the HTTP GET to the naming server returns a non-2xx status. The message embeds the upstream status code and body, letting you see the naming server's actual error (404 unknown namespace, 500 internal error, etc.) from the console's perspective.
Source
Thrown at console/src/main/java/org/apache/seata/mcp/service/impl/ConsoleRemoteServiceImpl.java:121
@Override
public String getCallNameSpace(String path) {
HttpHeaders headers = new HttpHeaders();
headers.add(WebSecurityConfig.AUTHORIZATION_HEADER, getToken());
String url = buildUrl(namingServerProperties.getNamingServerUrl(), path, null, null);
HttpEntity<String> entity = new HttpEntity<>(headers);
String responseBody;
try {
ResponseEntity<String> response = executeRequest(url, HttpMethod.GET, entity);
responseBody = response.getBody();
if (!response.getStatusCode().is2xxSuccessful()) {
String errorMsg = String.format(
"MCP GET request failed with status: %s, response: %s",
response.getStatusCode(), response.getBody());
LOGGER.warn(errorMsg);
throw new ServiceCallException(errorMsg, response.getStatusCode());
}
return responseBody;
} catch (RestClientException e) {
String errorMsg = "MCP GET Call NameSpace Failed.";
LOGGER.error(errorMsg, e);
throw new ServiceCallException(errorMsg);
}
}
@Override
public String getCallTC(
NameSpaceDetail nameSpaceDetail,
String path,
Object objectQueryParams,
Map<String, String> queryParams,
HttpHeaders headers) {
if (headers == null) {
headers = new HttpHeaders();View on GitHub (pinned to e01f97c6db)
Solutions
- Read the embedded status and body in the exception message — it is the naming server's real response and usually names the root cause
- Verify the namespace value sent in the x-seata-namespace header exists on the naming server
- Confirm console and naming-server versions match so REST paths agree
- For 401/403, check the forwarded JWT has access to the target namespace
Defensive patterns
Strategy: try-catch
Try / catch
try { body = service.getCallNameSpace(...); } catch (ServiceCallException e) { map status from exception to 404/403/502 response with the embedded upstream body; } Prevention
- Verify namespace names before querying
- Keep console and naming-server versions aligned
- Log the full embedded status+body for triage
When it happens
Trigger: Calling getCallNameSpace when the naming server endpoint rejects the request: unknown namespace header, 404 on the queried path, 401/403 from RBAC on the naming server, or 500 from a naming-server bug — i.e. connectivity is fine but the response status is not 2xx.
Common situations: Querying namespaces or vgroups that do not exist on the naming server; version mismatch between console and naming-server REST APIs (changed paths); missing permissions for the authenticated user on the target namespace.
Related errors
- No naming servers addr configured
- MCP GET Call NameSpace Failed.
- MCP DELETE request returned non-success status: %s, response
- The time format does not match yyyy-MM-dd
- The time format does not match yyyy-MM-dd HH:mm:ss
AI-assisted analysis of apache/incubator-seata@e01f97c6db (2026-08-14).
Data as JSON: /api/errors/cc567b8dd1fc0297.
Report an issue: GitHub.