{"record":{"id":"03bcb4facc88984c","repo":"alibaba/canal","slug":"extension-instance-name-class-could-not-03bcb4","errorCode":null,"errorMessage":"Extension instance(name: {}, class: {})  could not be instantiated: {}","messagePattern":"Extension instance\\(name: (.+?), class: (.+?)\\)  could not be instantiated: (.+?)","errorType":"exception","errorClass":"IllegalStateException","httpStatus":null,"severity":"error","filePath":"client-adapter/common/src/main/java/com/alibaba/otter/canal/client/adapter/support/ExtensionLoader.java","lineNumber":177,"sourceCode":"        return getExtension(cachedDefaultName);\n    }\n\n    @SuppressWarnings(\"unchecked\")\n    private T createExtension(String name) {\n        Class<?> clazz = getExtensionClasses().get(name);\n        if (clazz == null) {\n            throw new IllegalStateException(\"Extension instance(name: \" + name + \", class: \" + type\n                                            + \")  could not be instantiated: class could not be found\");\n        }\n        try {\n            T instance = (T) EXTENSION_INSTANCES.get(clazz);\n            if (instance == null) {\n                EXTENSION_INSTANCES.putIfAbsent(clazz, (T) clazz.newInstance());\n                instance = (T) EXTENSION_INSTANCES.get(clazz);\n            }\n            return instance;\n        } catch (Throwable t) {\n            throw new IllegalStateException(\"Extension instance(name: \" + name + \", class: \" + type\n                                            + \")  could not be instantiated: \" + t.getMessage(),\n                t);\n        }\n    }\n\n    @SuppressWarnings(\"unchecked\")\n    private T createExtension(String name, String key) {\n        Class<?> clazz = getExtensionClasses().get(name);\n        if (clazz == null) {\n            throw new IllegalStateException(\"Extension instance(name: \" + name + \", class: \" + type\n                                            + \")  could not be instantiated: class could not be found\");\n        }\n        try {\n            T instance = (T) EXTENSION_KEY_INSTANCE.get(name + \"-\" + key);\n            if (instance == null) {\n                EXTENSION_KEY_INSTANCE.putIfAbsent(name + \"-\" + key, clazz.newInstance());\n                instance = (T) EXTENSION_KEY_INSTANCE.get(name + \"-\" + key);\n            }","sourceCodeStart":159,"sourceCodeEnd":195,"githubUrl":"https://github.com/alibaba/canal/blob/87be50e87686a3e8af08c368d0e1ffd1f59eb04a/client-adapter/common/src/main/java/com/alibaba/otter/canal/client/adapter/support/ExtensionLoader.java#L159-L195","documentation":"Error \"Extension instance(name: {}, class: {})  could not be instantiated: {}\" thrown in alibaba/canal.","triggerScenarios":"Thrown at client-adapter/common/src/main/java/com/alibaba/otter/canal/client/adapter/support/ExtensionLoader.java:177 when the library encounters an invalid state.","commonSituations":"Extension class found but instantiation failed. Require a public no-arg constructor on extensions and propagate the root cause so plugin authors can fix construction errors.","solutions":["Inspect the instantiation error message; ensure the extension class has a public no-arg constructor and its dependencies are present.","Fix classloading conflicts if multiple versions of the adapter jar are on the classpath."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"87be50e87686a3e8af08c368d0e1ffd1f59eb04a","analyzedAt":"2026-08-14T04:30:11.918Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}