{"record":{"id":"7df0cc224edca79d","repo":"pinpoint-apm/pinpoint","slug":"not-found-method-classinternalname-methodnam","errorCode":null,"errorMessage":"not found method. ${classInternalName}.${methodName}","messagePattern":"not found method\\. (.+?)\\.(.+?)","errorType":"exception","errorClass":"InstrumentException","httpStatus":null,"severity":"error","filePath":"agent-module/profiler/src/main/java/com/navercorp/pinpoint/profiler/instrument/ASMAspectWeaver.java","lineNumber":113,"sourceCode":"        for (ASMMethodNodeAdapter methodNode : methodNodes.utils) {\n            if (!methodNode.isPrivate()) {\n                throw new InstrumentException(\"non private UtilMethod unsupported. method=\" + methodNode.getLongName());\n            }\n\n            classNode.copyMethod(methodNode);\n        }\n    }\n\n    private void copyPointCutMethods(final MethodNodes methodNodes, final ASMClassNodeAdapter classNode) throws InstrumentException {\n        final ASMMethodInsnNodeRemapper.Builder remapBuilder = new ASMMethodInsnNodeRemapper.Builder();\n        for (ASMMethodNodeAdapter joinPointMethodNode : methodNodes.jointPoints) {\n            remapBuilder.addFilter(null, joinPointMethodNode.getName(), joinPointMethodNode.getDesc());\n        }\n\n        for (ASMMethodNodeAdapter pointCutMethodNode : methodNodes.pointCuts) {\n            final ASMMethodNodeAdapter sourceMethodNode = classNode.getDeclaredMethod(pointCutMethodNode.getName(), pointCutMethodNode.getDesc());\n            if (sourceMethodNode == null) {\n                throw new InstrumentException(\"not found method. \" + classNode.getInternalName() + \".\" + pointCutMethodNode.getName());\n            }\n\n            if (!sourceMethodNode.getDesc().equals(pointCutMethodNode.getDesc())) {\n                throw new InstrumentException(\"Signature miss match. method=\" + pointCutMethodNode.getName() + \", source=\" + sourceMethodNode.getDesc() + \", advice=\" + pointCutMethodNode.getDesc());\n            }\n\n            if (logger.isInfoEnabled()) {\n                logger.info(\"weaving method={}{}\", sourceMethodNode.getName(), sourceMethodNode.getDesc());\n            }\n\n            // rename.\n            final String methodName = this.methodNameReplacer.replaceMethodName(sourceMethodNode.getName());\n            sourceMethodNode.rename(methodName);\n            // set private.\n            sourceMethodNode.setAccess(sourceMethodNode.getAccess() & -6 | Opcodes.ACC_PRIVATE);\n            // copy.\n            classNode.copyMethod(pointCutMethodNode);\n","sourceCodeStart":95,"sourceCodeEnd":131,"githubUrl":"https://github.com/pinpoint-apm/pinpoint/blob/744c3d3075e595656abb1ae331ad2c0e4c9eb996/agent-module/profiler/src/main/java/com/navercorp/pinpoint/profiler/instrument/ASMAspectWeaver.java#L95-L131","documentation":"copyPointCutMethods() weaves each @Interceptor pointcut method from the advice into the source class by looking up a declared method with the same name and descriptor. If the source class has no such method, InstrumentException is thrown with the class internal name and method name, since the join point does not exist.","triggerScenarios":"The advice class declares a pointcut method whose name does not match any method declared in the source class (name mismatch, method renamed/removed, or inherited-only methods that getDeclaredMethod does not return).","commonSituations":"Target library upgraded and the intercepted method was renamed or removed; advice written against an older version of the source class; typo in the pointcut method name.","solutions":["Update the pointcut method name to match the current source class method","Pin/adjust the plugin to the target library version that still declares the method","Confirm the method is declared (not just inherited) on the source class; getDeclaredMethod only sees declared methods","Dump the source class methods to verify the expected join point exists"],"exampleFix":"// before\npublic void interceptor_before_targetOldMethod(...) { ... }\n// after\npublic void interceptor_before_targetNewMethod(...) { ... }","handlingStrategy":"validation","validationCode":"if (sourceClassNode.getDeclaredMethod(pointCutName, pointCutDesc) == null) { throw new IllegalArgumentException(\"join point not declared: \" + pointCutName); }","typeGuard":null,"tryCatchPattern":"try { weaver.weaving(src, adv); } catch (InstrumentException e) { if (e.getMessage().startsWith(\"not found method.\")) { logger.error(\"stale pointcut after library upgrade: {}\", e.getMessage()); } }","preventionTips":["Keep advice in sync with target library versions","Pin dependency versions in plugin builds","Only target declared (not inherited) methods"],"tags":["java","bytecode","aspect","pointcut"],"backgroundTag":"resource-not-found","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"}