pinpoint-apm/pinpoint · error · UidException
Failed to get serviceUid. serviceName:${serviceName}
Error message
Failed to get serviceUid. serviceName:${serviceName} What it means
ServiceUidSuppliers.get wraps non-UidException failures of the underlying async lookup in a UidException with 'Failed to get serviceUid. serviceName:<name>' and the original cause. This normalizes ExecutionException into the module's own exception type while preserving the cause.
Source
Thrown at collector/src/main/java/com/navercorp/pinpoint/io/request/ServiceUidSuppliers.java:91
private static ServiceUid get(String serviceName, CompletableFuture<ServiceUid> future, long timeout, TimeUnit unit) {
try {
ServiceUid serviceUid = future.get(timeout, unit);
if (serviceUid == null) {
throw new UidNotFoundException(serviceName);
}
return serviceUid;
} catch (InterruptedException e) {
Thread.currentThread().interrupt();
throw new UidException("Interrupted while getting serviceUid. serviceName:" + serviceName, e);
} catch (TimeoutException e) {
throw new UidException("Timed out while getting serviceUid. serviceName:" + serviceName, e);
} catch (ExecutionException e) {
Throwable cause = e.getCause();
if (cause instanceof UidException uidException) {
throw uidException;
}
throw new UidException("Failed to get serviceUid. serviceName:" + serviceName, cause);
}
}
}
View on GitHub (pinned to 744c3d3075)
Solutions
- Inspect the UidException's cause for the root failure
- Fix or check the storage/query used by the serviceUid supplier
- If the cause is transient (network), retry the operation
- Ensure the supplier task handles null/absent service records gracefully
Defensive patterns
Strategy: try-catch
Try / catch
try { return supplier.get(serviceName); } catch (UidException e) { log.error("serviceUid lookup failed for {}", serviceName, e.getCause()); throw e; } Prevention
- Always log/inspect getCause() of UidException to find the root failure
- Make the uid supplier task defensive against null/absent records
- Add health checks for the metadata storage backing the supplier
When it happens
Trigger: get(serviceName) invoked when the serviceUid computation task itself throws (e.g. storage query failure, NPE in the supplier) — surfaced as ExecutionException whose cause is not already a UidException.
Common situations: Metadata storage outage or query error during agent registration; a bug in the uid-supplier task; deserialization failure of the stored uid value.
Related errors
- cannot leave with BOUNDARY trace scope. depth: ${depth}
- Timed out while getting serviceUid. serviceName:${serviceNam
- %s load fail Caused by:%s
- J9BootLoader create fail Caused by:
- initialize fail Caused by:
AI-assisted analysis of pinpoint-apm/pinpoint@744c3d3075 (2026-09-07).
Data as JSON: /api/errors/f2b5b9e101f98ad1.
Report an issue: GitHub.