{"record":{"id":"0bdbe71f89ab72e2","repo":"flowable/flowable-engine","slug":"the-jaxb-binding-definitions-are-not-found-for-flo","errorCode":null,"errorMessage":"The JAXB binding definitions are not found for flowable-cxf: \" + JAXB_BINDINGS_RESOURCE","messagePattern":"The JAXB binding definitions are not found for flowable-cxf: \" \\+ JAXB_BINDINGS_RESOURCE","errorType":"exception","errorClass":"FlowableException","httpStatus":null,"severity":"error","filePath":"modules/flowable-cxf/src/main/java/org/flowable/engine/impl/webservice/CxfWSDLImporter.java","lineNumber":138,"sourceCode":"                if (xjcBindingUrls.hasMoreElements()) {\n                    throw new FlowableException(\"Several JAXB binding definitions found for flowable-cxf: \" + JAXB_BINDINGS_RESOURCE);\n                }\n                DynamicClientFactory.newInstance(bus).createClient(url, Arrays.asList(new String[] { xjcBindingUrl.toString() }));\n                WSDLManager wsdlManager = bus.getExtension(WSDLManager.class);\n                Definition def = wsdlManager.getDefinition(url);\n                WSDLServiceBuilder builder = new WSDLServiceBuilder(bus);\n                List<ServiceInfo> services = builder.buildServices(def);\n\n                for (ServiceInfo service : services) {\n                    WSService wsService = this.importService(service);\n                    this.wsServices.put(this.namespace + wsService.getName(), wsService);\n                }\n\n                if (def != null && def.getTypes() != null) {\n                    this.importTypes(def.getTypes());\n                }\n            } else {\n                throw new FlowableException(\"The JAXB binding definitions are not found for flowable-cxf: \" + JAXB_BINDINGS_RESOURCE);\n            }\n        } catch (WSDLException e) {\n            e.printStackTrace();\n        } catch (IOException e) {\n            throw new FlowableException(\"Error retrieving the JAXB binding definitions\", e);\n        }\n    }\n\n    protected WSService importService(ServiceInfo service) {\n        String name = service.getName().getLocalPart();\n        String location = \"\";\n\n        for (EndpointInfo endpoint : service.getEndpoints()) {\n            location = endpoint.getAddress();\n        }\n\n        WSService wsService = new WSService(this.namespace + name, location, this.wsdlLocation);\n        for (OperationInfo operation : service.getInterface().getOperations()) {","sourceCodeStart":120,"sourceCodeEnd":156,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable-cxf/src/main/java/org/flowable/engine/impl/webservice/CxfWSDLImporter.java#L120-L156","documentation":"CxfWSDLImporter.importFrom requires a JAXB binding customization resource (JAXB_BINDINGS_RESOURCE) on the context classpath to generate the dynamic client. If the classloader enumerates zero resources with that name, it throws FlowableException 'The JAXB binding definitions are not found for flowable-cxf'.","triggerScenarios":"Calling importFrom when the context classloader cannot find the JAXB binding resource — the flowable-cxf jar is missing from the runtime classpath, or the resource was stripped by build filtering/shading excludes.","commonSituations":"Deploying an app without the flowable-cxf module jar; fat-jar shading excluding META-INF resources; custom classloader setups (application servers) not exposing the resource to the thread context classloader.","solutions":["Add the flowable-cxf dependency (and its transitive CXF/JAXB deps) to the runtime classpath.","Verify the resource exists via Thread.currentThread().getContextClassLoader().getResources(<JAXB_BINDINGS_RESOURCE>).","Fix maven-shade/assembly filters so the binding resource is not excluded from the artifact.","Ensure the thread context classloader is set correctly in OSGi/app-server environments."],"exampleFix":"// before: missing dependency\n// (no flowable-cxf on classpath)\n// after\n<dependency>\n  <groupId>org.flowable</groupId>\n  <artifactId>flowable-cxf</artifactId>\n  <version>6.7.2</version>\n</dependency>","handlingStrategy":"validation","validationCode":"if (!Thread.currentThread().getContextClassLoader().getResources(\"jaxb-bindings.xml\").hasMoreElements()) {\n    throw new IllegalStateException(\"flowable-cxf JAXB binding resource missing from classpath\");\n}","typeGuard":null,"tryCatchPattern":"try {\n    importer.importFrom(wsdlUrl);\n} catch (FlowableException e) {\n    if (e.getMessage().contains(\"not found for flowable-cxf\")) {\n        // add/fix flowable-cxf dependency and redeploy\n    }\n}","preventionTips":["Declare flowable-cxf as a runtime dependency wherever the WSDL importer runs.","Check shade/assembly filters do not strip the binding resource.","Fail fast at startup with a classpath self-check for the resource."],"tags":["cxf","jaxb","classpath","missing-resource"],"backgroundTag":"missing-dependency","analyzedSha":"d6d39ce1c69ff244f2d9dc6af756a9b95e865586","analyzedAt":"2026-09-11T06:41:19.413Z","contentChangedAt":"2026-09-11T06:41:19.413Z","schemaVersion":2},"datasetVersion":"2026-09-18T11:17:12.947Z"}