9 Replies Latest reply on Mar 21, 2008 4:33 AM by srbox

    WS producer example

    srbox

      Hello,

      I was trying to deploy the webservice_producer example from the quickstarts, but ran into

      ObjectName: jboss.esb:deployment=Quickstart_webservice_producer.esb
       State: FAILED
       Reason: java.lang.NoClassDefFoundError: org/jboss/wsf/spi/invocation/BasicInvocationContext
       I Depend On:
      ...
      


      I've found

      http://jira.jboss.org/jira/browse/SOA-102

      this JIRA issue but it was more of an internal discussion then and I couldn't get much out of it, and on the other thread

      http://www.jboss.com/index.html?module=bb&op=viewtopic&t=131503

      others seem to have made the example work. Can someone (rknaik?) please tell me what version or modification do I need to make the or which version do I need to get it going?

      Tnx in advance

      p.s.
      sorry about the links, but Murphys law turned against me on the url bbcodes.

        • 1. Re: WS producer example
          tfennelly

          Looks to be an issue with the version of JBossWS. Which version of the ESB are you using (src, distro etc)? How are you running the example (sounds like you're running it in JBossAS - which version)?

          • 2. Re: WS producer example
            srbox

            Hi,

            it's JBossESB 4.2.1GA deployed on JBoss 4.2.2GA.

            • 3. Re: WS producer example
              troyer

              I have the same problem, AS is 4.2.2GA:

              1. Deploy JBossESB 4.2.1GA by running "ant", deploy.properties are set correctly
              2. Deploy JBossWS 2.0.3 by running "ant deploy-jboss422"
              3. Then run the Webservices_producer & got the same "NoClassDefFoundError".

              Any suggestion on how to fix this problem??

              • 4. Re: WS producer example
                kconner

                Try deploying JBossWS 2.0.1, it should solve this problem. We haven't tested ESB 4.2.1GA against AS 4.2.2 so there may be other issues.

                Support for As 4.2.2GA and JBossWS 2.0.3 will be in the next release of the project.

                • 5. Re: WS producer example
                  tfennelly

                  Please consult page 17 of the Admin Guide in the JBossESB 4.2.1.GA release re configuring your AS for ESB Webservices.

                  JBossESB 4.2.1.GA was only "certified" to run on JBoss AS 4.2.1.GA (not 4.2.2.GA).

                  • 6. Re: WS producer example
                    srbox

                    Hi guys,

                    I've managed to deploy the example. The end combination was:

                    JBossAS 4.2.1GA
                    JBossWS native 2.0.0GA (2.0.1 didn't work with the JAXB Introductions/patch tfennelly pointed out in the Admin guide)
                    JBossESB 4.2.1GA

                    Deployments runs ok, but client side of "ant runtest" returns exceptions:

                    saygoodbye_over_http:
                     [echo] Invoking a JBossWS Endpoint over HTTP (via JBoss ESB).
                     [java] Calling JBoss Remoting Listener using locator URI: http://localhost:
                    8765
                     [java] Exception in thread "main" org.jboss.remoting.CannotConnectException
                    : Can not connect http client invoker.
                     [java] at org.jboss.remoting.transport.http.HTTPClientInvoker.useHttpUR
                    LConnection(HTTPClientInvoker.java:332)
                     [java] at org.jboss.remoting.transport.http.HTTPClientInvoker.transport
                    (HTTPClientInvoker.java:135)
                     [java] at org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemot
                    eClientInvoker.java:122)
                     [java] at org.jboss.remoting.Client.invoke(Client.java:1550)
                     [java] at org.jboss.remoting.Client.invoke(Client.java:530)
                     [java] at org.jboss.remoting.Client.invoke(Client.java:518)
                     [java] at org.jboss.soa.esb.samples.quickstart.webserviceproducer.test.
                    SendMessage.sendMessageToJBRListener(SendMessage.java:72)
                     [java] at org.jboss.soa.esb.samples.quickstart.webserviceproducer.test.
                    SendMessage.main(SendMessage.java:114)
                     [java] Caused by: java.io.StreamCorruptedException: invalid stream header
                     [java] at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.
                    java:764)
                     [java] at java.io.ObjectInputStream.<init>(ObjectInputStream.java:277)
                     [java] at org.jboss.remoting.loading.ObjectInputStreamWithClassLoader.<
                    init>(ObjectInputStreamWithClassLoader.java:95)
                     [java] at org.jboss.remoting.serialization.impl.java.JavaSerializationM
                    anager.createInput(JavaSerializationManager.java:54)
                     [java] at org.jboss.remoting.marshal.serializable.SerializableUnMarshal
                    ler.getMarshallingStream(SerializableUnMarshaller.java:72)
                     [java] at org.jboss.remoting.marshal.serializable.SerializableUnMarshal
                    ler.read(SerializableUnMarshaller.java:119)
                     [java] at org.jboss.remoting.marshal.http.HTTPUnMarshaller.read(HTTPUnM
                    arshaller.java:69)
                     [java] at org.jboss.remoting.transport.http.HTTPClientInvoker.readRespo
                    nse(HTTPClientInvoker.java:470)
                     [java] at org.jboss.remoting.transport.http.HTTPClientInvoker.useHttpUR
                    LConnection(HTTPClientInvoker.java:304)
                     [java] ... 7 more
                    


                    The server side on the other hand looks like this:

                    14:41:14,046 INFO [STDOUT] [Quickstart_webservice_producer] BEFORE invoking jbo
                    ssws endpoint:
                    14:41:14,046 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xml
                    soap.org/soap/envelope/" xmlns:good="http://webservice_producer/goodbyeworld">
                     <soapenv:Header/>
                     <soapenv:Body>
                     <good:sayGoodbye>
                     <message>Goodbye!!</message>
                     </good:sayGoodbye>
                     </soapenv:Body>
                    </soapenv:Envelope>].
                    14:41:14,062 INFO [STDOUT] **** SOAPRequest perhaps mediated by ESB:
                    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmln
                    s:good="http://webservice_producer/goodbyeworld">
                     <soapenv:Header/>
                     <soapenv:Body>
                     <good:sayGoodbye>
                     <message>Goodbye!!</message>
                     </good:sayGoodbye>
                     </soapenv:Body>
                    </soapenv:Envelope>
                    14:41:14,062 INFO [STDOUT] Web Service Parameter - message=Goodbye!!
                    14:41:14,062 INFO [STDOUT] [Quickstart_webservice_producer] AFTER invoking jbos
                    sws endpoint:
                    14:41:14,062 INFO [STDOUT] [<env:Envelope xmlns:env='http://schemas.xmlsoap.org
                    /soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayGoodbyeResponse xmln
                    s:ns2="http://webservice_producer/goodbyeworld"><return>... Ah Goodbye then!!!!
                    - Goodbye!!</return></ns2:sayGoodbyeResponse></env:Body></env:Envelope>].
                    14:41:14,062 WARN [ActionProcessingPipeline] No reply to address defined for re
                    ply message! To: JMSEpr [ PortReference < <wsa:Address jms://localhost/queue/qui
                    ckstart_webservice_producer_esb/>, <wsa:ReferenceProperties jbossesb:java.naming
                    .factory.initial : org.jnp.interfaces.NamingContextFactory/>, <wsa:ReferenceProp
                    erties jbossesb:java.naming.provider.url : localhost/>, <wsa:ReferenceProperties
                     jbossesb:destination-type : queue/>, <wsa:ReferenceProperties jbossesb:specific
                    ation-version : 1.1/>, <wsa:ReferenceProperties jbossesb:connection-factory : Co
                    nnectionFactory/>, <wsa:ReferenceProperties jbossesb:persistent : true/>, <wsa:R
                    eferenceProperties jbossesb:acknowledge-mode : 1/> > ] MessageID: ID:2-120602047
                    40305 RelatesTo: jms:correlationID#ID:4-12060204739831
                    14:41:17,030 WARN [ServiceInvoker] Badly formed EPR [EPR: PortReference < <wsa:
                    Address http://localhost:8765/> >] for Service [MyServiceCategory:MyWSProducerSe
                    rvice] and Message [header: [ ]].Courier for EPR not supported!
                    14:41:17,030 INFO [ServiceInvoker] Invalid EPR for service: ignoring for messag
                    e: header: [ ]
                    14:41:17,030 WARN [ServiceInvoker] Badly formed EPR [EPR: PortReference < <wsa:
                    Address socket://localhost:8888/> >] for Service [MyServiceCategory:MyWSProducer
                    Service] and Message [header: [ ]].Courier for EPR not supported!
                    14:41:17,030 INFO [ServiceInvoker] Invalid EPR for service: ignoring for messag
                    e: header: [ ]
                    14:41:17,218 INFO [STDOUT] [Quickstart_webservice_producer] BEFORE invoking jbo
                    ssws endpoint:
                    14:41:17,218 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xml
                    soap.org/soap/envelope/" xmlns:good="http://webservice_producer/goodbyeworld">
                     <soapenv:Header/>
                     <soapenv:Body>
                     <good:sayGoodbye>
                     <message>Goodbye!!</message>
                     </good:sayGoodbye>
                     </soapenv:Body>
                    </soapenv:Envelope>].
                    14:41:17,233 INFO [STDOUT] **** SOAPRequest perhaps mediated by ESB:
                    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmln
                    s:good="http://webservice_producer/goodbyeworld">
                     <soapenv:Header/>
                     <soapenv:Body>
                     <good:sayGoodbye>
                     <message>Goodbye!!</message>
                     </good:sayGoodbye>
                     </soapenv:Body>
                    </soapenv:Envelope>
                    14:41:17,233 INFO [STDOUT] Web Service Parameter - message=Goodbye!!
                    14:41:17,233 INFO [STDOUT] [Quickstart_webservice_producer] AFTER invoking jbos
                    sws endpoint:
                    14:41:17,233 INFO [STDOUT] [<env:Envelope xmlns:env='http://schemas.xmlsoap.org
                    /soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayGoodbyeResponse xmln
                    s:ns2="http://webservice_producer/goodbyeworld"><return>... Ah Goodbye then!!!!
                    - Goodbye!!</return></ns2:sayGoodbyeResponse></env:Body></env:Envelope>].
                    


                    Any idea on that one? I just need info if the problem is related to my configuration or is it in the example itself. In either way, thank you for the help so far!


                    • 7. Re: WS producer example
                      troyer

                      Thanks for the tips!! I used the versions you suggested, and I got the webservice_producer server to deploy.

                      But I am experiencing the same error on the client side. Do we need to install a different version of Remoting??

                      Any insight is greatly appreciated!!

                      • 8. Re: WS producer example
                        troyer

                        Hi,

                        I got both the server & client working by downloading the JBossRemoting 2.2.2SP2. Look at the readme.htm for the QuickStart webservice_wssecurity.

                        Once I replace the jboss-remoting.jar in the ESB server, then the client deploy successfully.

                        Thanks everyone for the help!

                        • 9. Re: WS producer example
                          srbox

                          Great find troyer, thanks a lot! This would be the end of the producer problem.

                          JBoss-guys, could you include the JBossRemoting 2.2.2SP2 note in the readme file for the next version?

                          Thanks to all who helped out with this.

                          All the best.