{"record":{"id":"ab91a07c4d81375b","repo":"pinpoint-apm/pinpoint","slug":"unknown-matcher-type","errorCode":null,"errorMessage":"Unknown matcher type : ","messagePattern":"Unknown matcher type : ","errorType":"exception","errorClass":"IllegalStateException","httpStatus":null,"severity":"error","filePath":"agent-module/plugins-loader/src/main/java/com/navercorp/pinpoint/loader/plugins/trace/yaml/ParsedAnnotationKeyMatcher.java","lineNumber":61,"sourceCode":"    }\n\n    public void setCode(Integer code) {\n        this.code = code;\n    }\n\n    AnnotationKeyMatcher toAnnotationKeyMatcher() {\n        if (StringUtils.isEmpty(type)) {\n            throw new IllegalArgumentException(\"matcher type must not be empty\");\n        }\n        if (type.equalsIgnoreCase(\"exact\")) {\n            Objects.requireNonNull(code, \"code must not be null for matcher type 'exact'\");\n            return AnnotationKeyMatchers.exact(code);\n        } else if (type.equalsIgnoreCase(\"args\")) {\n            return AnnotationKeyMatchers.ARGS_MATCHER;\n        } else if (type.equalsIgnoreCase(\"none\")) {\n            return AnnotationKeyMatchers.NOTHING_MATCHER;\n        }\n        throw new IllegalStateException(\"Unknown matcher type : \" + type);\n    }\n}\n","sourceCodeStart":43,"sourceCodeEnd":64,"githubUrl":"https://github.com/pinpoint-apm/pinpoint/blob/744c3d3075e595656abb1ae331ad2c0e4c9eb996/agent-module/plugins-loader/src/main/java/com/navercorp/pinpoint/loader/plugins/trace/yaml/ParsedAnnotationKeyMatcher.java#L43-L64","documentation":"Thrown by ParsedAnnotationKeyMatcher.toAnnotationKeyMatcher when the matcher 'type' is non-empty but not one of the supported values: exact, args, or none. The loader cannot map the unknown type to an AnnotationKeyMatcher and aborts plugin metadata loading.","triggerScenarios":"YAML type-provider definition declares annotationKeyMatcher with type like 'regex', 'prefix', 'startsWith', or a misspelled 'excat' — anything not matching exact/args/none case-insensitively.","commonSituations":"Authors assuming matcher types from other libraries (regex/prefix) are supported; typos in 'exact'/'args'/'none'; outdated documentation or copied configs from incompatible plugin versions.","solutions":["Change type to one of the supported values: exact, args, or none","Fix typos in the type value (matching is case-insensitive, so 'EXACT' is fine)","If custom matching is required, implement it in the plugin code rather than via yaml matcher type","Compare with existing plugin yamls in the pinpoint repository for valid examples"],"exampleFix":"// before (plugin yaml)\nannotationKeyMatcher:\n  - code: 900\n    type: prefix\n// after\nannotationKeyMatcher:\n  - code: 900\n    type: exact","handlingStrategy":"validation","validationCode":"String t = matcher.getType();\nif (t != null && !Set.of(\"exact\",\"args\",\"none\").contains(t.toLowerCase())) {\n  throw new IllegalStateException(\"unsupported matcher type '\" + t + \"'; use exact|args|none\");\n}","typeGuard":null,"tryCatchPattern":"try { matcher = parsed.toAnnotationKeyMatcher(); } catch (IllegalStateException e) { if (e.getMessage().startsWith(\"Unknown matcher type\")) { log.error(\"supported types: exact, args, none\"); } throw e; }","preventionTips":["Only use exact/args/none as matcher types (case-insensitive)","Do not assume matcher types from other frameworks (regex/prefix are unsupported)","Validate yamls against pinpoint plugin examples before release"],"tags":["java","yaml","plugin","validation"],"backgroundTag":"invalid-enum-value","analyzedSha":"744c3d3075e595656abb1ae331ad2c0e4c9eb996","analyzedAt":"2026-09-07T18:48:45.289Z","contentChangedAt":"2026-09-07T18:48:45.289Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}