{"record":{"id":"3026e0f644d637ae","repo":"pinpoint-apm/pinpoint","slug":"error-api-metadata-not-found","errorCode":"ERROR_API_METADATA_NOT_FOUND","errorMessage":"CACHED-STRING-ID not found. stringId:","messagePattern":"CACHED-STRING-ID not found\\. stringId:","errorType":"error_code","errorClass":null,"httpStatus":null,"severity":"error","filePath":"web/src/main/java/com/navercorp/pinpoint/web/trace/service/SpanServiceImpl.java","lineNumber":656,"sourceCode":"    private AnnotationReplacementCallback transitionCachedString() {\n        return new AnnotationReplacementCallback() {\n            @Override\n            public void replacement(Align align, List<AnnotationBo> annotationBoList, MetadataAccessor metadataAccessor) {\n\n                List<AnnotationBo> cachedStringAnnotation = AnnotationUtils.findAnnotations(annotationBoList,\n                        e -> AnnotationKeyUtils.isCachedArgsKey(e.getKey()));\n                if (cachedStringAnnotation.isEmpty()) {\n                    return;\n                }\n                for (AnnotationBo annotationBo : cachedStringAnnotation) {\n                    final int cachedArgsKey = annotationBo.getKey();\n                    int stringMetaDataId = (Integer) annotationBo.getValue();\n                    List<StringMetaDataBo> stringMetaList = metadataAccessor.getStringMetaData(align.getServiceUid(), align.getAgentId(), align.getAgentStartTime(), stringMetaDataId);\n                    int size = stringMetaList.size();\n                    if (size == 0) {\n                        logger.warn(\"StringMetaData not Found {}/{}/{}\", align.getAgentId(), stringMetaDataId, align.getAgentStartTime());\n                        String errorMessage = \"CACHED-STRING-ID not found. stringId:\";\n                        AnnotationBo api = AnnotationBo.of(AnnotationKey.ERROR_API_METADATA_NOT_FOUND.getCode(), errorMessage);\n                        annotationBoList.add(api);\n                    } else if (size >= 1) {\n                        // key collision shouldn't really happen (probability too low)\n                        StringMetaDataBo stringMetaDataBo = stringMetaList.get(0);\n\n                        AnnotationBo stringMetaData = AnnotationBo.of(AnnotationKeyUtils.cachedArgsToArgs(cachedArgsKey), stringMetaDataBo.getStringValue());\n                        annotationBoList.add(stringMetaData);\n                        if (size > 1) {\n                            logger.warn(\"stringMetaData size not 1 :{}\", stringMetaList);\n                        }\n                    }\n                }\n            }\n\n\n        };\n    }\n","sourceCodeStart":638,"sourceCodeEnd":674,"githubUrl":"https://github.com/pinpoint-apm/pinpoint/blob/744c3d3075e595656abb1ae331ad2c0e4c9eb996/web/src/main/java/com/navercorp/pinpoint/web/trace/service/SpanServiceImpl.java#L638-L674","documentation":"Warn-level diagnostic in SpanServiceImpl's cached-string replacement: a cached-args annotation references a stringId that is absent from the cached string dictionary, so the annotation cannot be resolved to its original string value.","triggerScenarios":"Thrown at web/src/main/java/com/navercorp/pinpoint/web/trace/service/SpanServiceImpl.java:656 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify string metadata was fully flushed before the query window","Check for stringId/agentStartTime mismatches caused by agent restarts","Fall back to rendering the raw annotation value when lookup misses"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"744c3d3075e595656abb1ae331ad2c0e4c9eb996","analyzedAt":"2026-09-07T18:48:45.289Z","contentChangedAt":"2026-09-07T18:48:45.289Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}