Switchyard application fails to deploy with 'SWITCHYARD016853: Invalid Transformer class' error when transformer class is in separate jar
Issue
We have several Switchyard projects using Java Transformers to transform from SOAP-Fault to java exceptions. These are working fine as long as these java classes are packaged inside the Switchyard project. But we want to reuse some of these Transformers within other Switchyard projects so we came to the solution to put these java classes into a separate maven project in order to use it as a maven dependency. There is no problem with the build of these project but during deployment, the server is not able to load the transformers correctly:
14:39:04,505 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-2) MSC000001: Failed to start service jboss.deployment.subunit."switchyard-ear-deployment.ear"."switchyard-ear-deployment-order-service-2.1.0.redhat-630187.jar".SwitchYardService: org.jboss.msc.service.StartException in service jboss.deployment.subunit."switchyard-ear-deployment.ear"."switchyard-ear-deployment-order-service-2.1.0.redhat-630187.jar".SwitchYardService: org.switchyard.SwitchYardException: SWITCHYARD016853: Invalid Transformer class 'org.switchyard.quickstarts.demo.multiapp.Transformers'. Must implement the Transformer interface, or have methods annotated with the @Transformer annotation.
at org.switchyard.as7.extension.services.SwitchYardService.start(SwitchYardService.java:84)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1980) [jboss-msc-1.1.6.Final-redhat-1.jar:1.1.6.Final-redhat-1]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1913) [jboss-msc-1.1.6.Final-redhat-1.jar:1.1.6.Final-redhat-1]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0_91]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0_91]
at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_91]
Caused by: org.switchyard.SwitchYardException: SWITCHYARD016853: Invalid Transformer class 'org.switchyard.quickstarts.demo.multiapp.Transformers'. Must implement the Transformer interface, or have methods annotated with the @Transformer annotation.
at org.switchyard.transform.internal.TransformerUtil.newTransformers(TransformerUtil.java:72)
at org.switchyard.transform.internal.TransformerRegistryLoader.newTransformers(TransformerRegistryLoader.java:250)
at org.switchyard.transform.internal.TransformerRegistryLoader.registerTransformers(TransformerRegistryLoader.java:124)
at org.switchyard.transform.internal.TransformerRegistryLoader.registerTransformers(TransformerRegistryLoader.java:108)
at org.switchyard.deploy.internal.Deployment.registerTransformers(Deployment.java:271)
at org.switchyard.deploy.internal.Deployment.doInit(Deployment.java:117)
at org.switchyard.deploy.internal.AbstractDeployment.init(AbstractDeployment.java:147)
at org.switchyard.as7.extension.deployment.SwitchYardDeployment.start(SwitchYardDeployment.java:125)
at org.switchyard.as7.extension.services.SwitchYardService.start(SwitchYardService.java:77)
... 5 more
Environment
- Red Hat JBoss Fuse
- 6.3.0
- Red Hat JBoss EAP
- 6.4
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.