{"record":{"id":"552cf8077cb10585","repo":"apache/dubbo","slug":"missing-method-implement","errorCode":null,"errorMessage":"Missing method [{}] implement.","messagePattern":"Missing method \\[(.+?)\\] implement\\.","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"dubbo-common/src/main/java/org/apache/dubbo/common/bytecode/Mixin.java","lineNumber":149,"sourceCode":"                    }\n                }\n\n                ccp.addInterface(ics[i]);\n\n                for (Method method : ics[i].getMethods()) {\n                    if (\"java.lang.Object\".equals(method.getDeclaringClass().getName())) {\n                        continue;\n                    }\n\n                    String desc = ReflectUtils.getDesc(method);\n                    if (worked.contains(desc)) {\n                        continue;\n                    }\n                    worked.add(desc);\n\n                    int ix = findMethod(dcs, desc);\n                    if (ix < 0) {\n                        throw new RuntimeException(\"Missing method [\" + desc + \"] implement.\");\n                    }\n\n                    Class<?> rt = method.getReturnType();\n                    String mn = method.getName();\n                    if (Void.TYPE.equals(rt)) {\n                        ccp.addMethod(\n                                mn,\n                                method.getModifiers(),\n                                rt,\n                                method.getParameterTypes(),\n                                method.getExceptionTypes(),\n                                \"d\" + ix + \".\" + mn + \"($$);\");\n                    } else {\n                        ccp.addMethod(\n                                mn,\n                                method.getModifiers(),\n                                rt,\n                                method.getParameterTypes(),","sourceCodeStart":131,"sourceCodeEnd":167,"githubUrl":"https://github.com/apache/dubbo/blob/3a3043227f5571d25eb2889de5bca22f2914843b/dubbo-common/src/main/java/org/apache/dubbo/common/bytecode/Mixin.java#L131-L167","documentation":"Thrown by Mixin.mixin when an interface declares a method that none of the supplied delegate classes implement (findMethod returns -1). The message includes the method descriptor so you can see exactly which signature is missing. Because the generated class would not satisfy the interface, Dubbo fails fast with RuntimeException.","triggerScenarios":"Mixin.mixin(ics, dcs) where a delegate class omits a public method required by one of the interfaces; the delegate has the method but it is private/static so it is not returned by getMethods().","commonSituations":"A delegate that implements only part of an interface; a delegate whose required method is package-private or static and thus invisible to reflection; an interface that gained a new method after the delegate was compiled.","solutions":["Implement the missing method (matching the exact signature in the descriptor) as a public method on a delegate class.","If the method exists but is private/static/protected, change it to public instance scope so getMethods() sees it.","Add the new interface method to all delegates after upgrading the interface."],"exampleFix":"// before\npublic class DelegateImpl implements Service {\n    public void a() {}\n    // b() missing\n}\n\n// after\npublic class DelegateImpl implements Service {\n    public void a() {}\n    public void b() {} // satisfy Service.b()\n}","handlingStrategy":"validation","validationCode":"for (Class<?> dc : dcs) {\n    for (Method m : ics_to_check.getMethods()) {\n        boolean found = Arrays.stream(dc.getMethods())\n            .anyMatch(dm -> ReflectUtils.getDesc(dm).equals(ReflectUtils.getDesc(m)));\n        if (!found) { /* delegate is missing a required method */ }\n    }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Make delegates implement the full interface (use `implements Iface` so the compiler enforces it).","Keep required methods public and non-static so reflection sees them.","Re-run Mixin.mixin in a unit test whenever the interface changes."],"tags":["bytecode","mixin","interface","validation"],"backgroundTag":null,"analyzedSha":"3a3043227f5571d25eb2889de5bca22f2914843b","analyzedAt":"2026-08-14T00:43:19.853Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}