1 2 Previous Next 29 Replies Latest reply on Jul 18, 2013 11:01 AM by ganesan.sankara Go to original post
      • 15. Re: Outbound JCA
        igarashitm

        can you attach the log?

        • 16. Re: Outbound JCA
          boanergesza11

          Arg, now it seems with all my messing around I have broken something. previously we have been able to deploy all he jars seperately and everuthing worked. Now for some reason its not working.

           

          What are you hoping to see in the logs? Because Im starting to get the idea it might be a switchayrd problem, and not a configuration problem in my app.

          • 17. Re: Outbound JCA
            boanergesza11

            OK, so now we have just lumped all the "exstras" we had in that interface jar, into the switchyard jar. We then started up with only the jca, then we started copied in the SY jar....no suprises its the same result.

            Log attached.

            • 18. Re: Outbound JCA
              boanergesza11

              Just for interest sake:

               

              https://docs.jboss.org/author/display/SWITCHYARD/JCA+Bindings from the readme of hornetq jca readme quickstart gives:

               

              JCA Bindings (Page Deleted)

              • 19. Re: Outbound JCA
                igarashitm

                The last log is the start line I have been looking for. I couldn't  find any clue from the logs you provided before this - one has EAR  packaging problem, and the other has deployment order problem. So I have  been asking you to try sequential deploy with your RAR and SwitchYard  JAR but not using EAR.

                 

                So your last log suggested  SwitchYard JCA couldn't find your ResourceAdapter registered with the  name 'socketjca.rar', despite of that the socketjca.rar is already  deployed. I'm now thinking 1 of following may be the cause:

                 

                1) socketjca.rar is deployed with different name (ra.xml in the RAR may affect this)

                2) socketjca.rar is not visible from SwitchYard JAR

                 

                Unfortunately I don't have time to try your RAR and JAR on my PC right now. Thank you for your patience.

                • 20. Re: Outbound JCA
                  igarashitm

                  Thanks for catching this, I filed a JIRA

                  https://issues.jboss.org/browse/SWITCHYARD-1572

                  • 21. Re: Outbound JCA
                    boanergesza11

                    Thanks for you help on that. We are tearing our hair out overhere. This one problem is holding up a lot of development here and tied two guys down with it. Price one pays for cutting edge I suspose!

                    • 22. Re: Outbound JCA
                      igarashitm

                      Have you ever tried to add jboss-deployment-structure.xml in your SwitchYard JAR?

                      https://community.jboss.org/message/816611#816611

                       

                      If 2) is the cause, jboss-deployment-structure.xml may solve it.

                      • 23. Re: Outbound JCA
                        boanergesza11

                        AHA!!! Finally we have gotten somewhere:

                         


                        -SNAPSHOT.jar".STRUCTURE: org.jboss.msc.service.StartException in service jboss.deployment.unit."MPowaPOSToGateway-0.0.1-SNAPSHOT.jar".STRUCTURE: Failed

                        to process phase STRUCTURE of deployment "MPowaPOSToGateway-0.0.1-SNAPSHOT.jar"

                                at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:119) [jboss-as-server-7.1.1.Final.jar:7.1.1.F

                        nal]

                                at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]

                                at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]

                                at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_21]

                                at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_21]

                                at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_21]

                        Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: Error loading jboss-structure.xml from D:\servers\switchyard-as7-0.8\standa

                        one\tmp\vfs\tempa3cb78b905d9a777\MPowaPOSToGateway-0.0.1-SNAPSHOT.jar-4548439dd8b459fd\contents\META-INF\jboss-deployment-structure.xml

                                at org.jboss.as.server.deployment.module.descriptor.DeploymentStructureDescriptorParser.parse(DeploymentStructureDescriptorParser.java:277) [jbo

                        s-as-server-7.1.1.Final.jar:7.1.1.Final]

                                at org.jboss.as.server.deployment.module.descriptor.DeploymentStructureDescriptorParser.parse(DeploymentStructureDescriptorParser.java:249) [jbo

                        s-as-server-7.1.1.Final.jar:7.1.1.Final]

                                at org.jboss.as.server.deployment.module.descriptor.DeploymentStructureDescriptorParser.deploy(DeploymentStructureDescriptorParser.java:134) [jb

                        ss-as-server-7.1.1.Final.jar:7.1.1.Final]

                                at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:113) [jboss-as-server-7.1.1.Final.jar:7.1.1.F

                        nal]

                                ... 5 more

                        Caused by: javax.xml.stream.XMLStreamException: ParseError at [row,col]:[4,3]

                        Message: Unexpected content of type 'element start' named 'dependencies'

                                at org.jboss.as.server.deployment.module.descriptor.JBossDeploymentStructureParser11.unexpectedContent(JBossDeploymentStructureParser11.java:109

                        ) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]

                                at org.jboss.as.server.deployment.module.descriptor.JBossDeploymentStructureParser11.readElement(JBossDeploymentStructureParser11.java:220) [jbo

                        s-as-server-7.1.1.Final.jar:7.1.1.Final]

                                at org.jboss.as.server.deployment.module.descriptor.JBossDeploymentStructureParser11.readElement(JBossDeploymentStructureParser11.java:42) [jbos

                        -as-server-7.1.1.Final.jar:7.1.1.Final]

                                at org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:110) [staxmapper-1.1.0.Final.jar:1.1.0.Final]

                                at org.jboss.staxmapper.XMLMapperImpl.parseDocument(XMLMapperImpl.java:69) [staxmapper-1.1.0.Final.jar:1.1.0.Final]

                                at org.jboss.as.server.deployment.module.descriptor.DeploymentStructureDescriptorParser.parse(DeploymentStructureDescriptorParser.java:271) [jbo

                        s-as-server-7.1.1.Final.jar:7.1.1.Final]

                                ... 8 more

                        • 24. Re: Outbound JCA
                          boanergesza11

                          AH , the mistake I made there was not to add the dependencies tag in a deployment tag. Fixed that, now we are back to "Unique key for ResourceAdapter 'socketjca.rar' couldn't be found."

                          • 25. Re: Outbound JCA
                            igarashitm

                            I took a look at your socketjca.rar and noticed your ra.xml doesn't specify the resourceadapter-class which implements javax.resource.spi.ResourceAdapter. I think your socketjca.rar is not registered as a ResourceAdapter properly.

                             

                            for example:

                            <connector id="Connector_ID" version="1.5" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/connector_1_5.xsd"> 
                              <description>Socket JCA</description>
                              <display-name>SocketJCA</display-name>
                              <vendor-name></vendor-name>
                              <eis-type>Socket</eis-type>
                              <resourceadapter-version>1.0</resourceadapter-version>
                              <resourceadapter>
                                <resourceadapter-class>za.co.fnb.jca.eis.ResourceAdapterImpl</resourceadapter-class>
                                <outbound-resourceadapter>
                                  <connection-definition>
                            
                            (...snip...)
                            
                            • 26. Re: Outbound JCA
                              boanergesza11

                              OK;

                               

                              So we have finally given up getting switchyard to recognize our custom JCA. Nothing we have done has made it available to the Switchyard app we have built. Here is a list of things we tried for posterity's sake:

                              1. We have seperated our custom JCA out of the EAR file and deployed it seperately. Although JBoss deployes it and its listed in the JNDI view on the console, Switchyard is unable to find it.
                              2. We have seperated the EAR file out in the seperate pieces and deployed each jar on its own. We have also combined all the sepearte jars in one big SY jar file we also removed everything and just had the JCA code in it.
                              3. We have added the dependency in the MANIFEST.MF file
                              4. We tried to use jboss-deployment-structure.xml in the ear file.
                              5. We deployed the ear as a module (ALA hornetQ)

                               

                              Not of these worked and we are stuck with the the same error message everytime.

                              We have now run out of time to further explore other options to solve this problem and will now be doing a JNDI lookup to that JCA instead of using SY to manage it so we can get our project moving along. However if we find a solution we shall revert back to having SY manage that for us and, critically, post it here!

                               

                              Im starting to think this might be an issue in SwitchYard itself. One thing that I have notived though, is that we are using the "old" way of doing JCA, that is with a ra.xml file and not annotations. Could this be it?

                               

                              Resource Adapter

                              Service: java.lang.IllegalArgumentException: Unique key for ResourceAdapter 'socketjca.rar' couldn't be found.

                                      at org.switchyard.as7.extension.services.SwitchYardService.start(SwitchYardService.java:85)

                                      at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]

                                      at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]

                                      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_21]

                                      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_21]

                                      at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_21]

                              Caused by: java.lang.IllegalArgumentException: Unique key for ResourceAdapter 'socketjca.rar' couldn't be found.

                                      at org.switchyard.component.jca.deploy.JCAActivator.handleReferenceBinding(JCAActivator.java:211)

                                      at org.switchyard.component.jca.deploy.JCAActivator.activateBinding(JCAActivator.java:92)

                                      at org.switchyard.deploy.internal.Deployment.deployReferenceBindings(Deployment.java:274)

                                      at org.switchyard.deploy.internal.Deployment.start(Deployment.java:139)

                                      at org.switchyard.as7.extension.deployment.SwitchYardDeployment.start(SwitchYardDeployment.java:106)

                                      at org.switchyard.as7.extension.services.SwitchYardService.start(SwitchYardService.java:78)

                                      ... 5 more

                              • 27. Re: Outbound JCA
                                igarashitm

                                You may want to take a look at this ResourceAdapter:

                                 

                                [JBoss SAP JCA Connector]

                                https://github.com/punkhorn/jboss-sap-jca

                                 

                                [SwitchYard application using JBoss SAP JCA Connector]

                                https://github.com/igarashitm/switchyard-sap-jca

                                 

                                HornetQ, ActiveMQ and above SAP could be connected from SwitchYard JCA outbound via its ResourceAdapter.

                                • 28. Re: Outbound JCA
                                  boanergesza11

                                  I might have posted before I saw your previous answer. Busy checking that now.

                                  • 29. Re: Outbound JCA
                                    ganesan.sankara

                                    I have the same problem. Using 0.8.0.Final.  if I deploy active mq rar alone it works.. along with my app both deployments fault

                                     


                                    1 2 Previous Next