3 Replies Latest reply on Jan 19, 2009 8:06 PM by HC Kanty

    I deploy the bpel file successful, but when I used axis clie

    HC Kanty Newbie

      I build the jbossesb-4.4.GA example , it generated Quickstart_webservice_consumer_wise.war and I deployed it on the jbossesb server successful.
      I got the wsdl file on "http://192.168.18.101:8080/Quickstart_webservice_consumer_wise/HelloWorldWS?wsdl"

      <definitions name='HelloWorldWSService' targetNamespace='http://webservice_consumer_wise/helloworld' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://webservice_consumer_wise/helloworld' xmlns:xsd='http://www.w3.org/2001/XMLSchema' xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype">
       <types>
       <xs:schema targetNamespace='http://webservice_consumer_wise/helloworld' version='1.0' xmlns:tns='http://webservice_consumer_wise/helloworld' xmlns:xs='http://www.w3.org/2001/XMLSchema'>
       <xs:element name='sayHello' type='tns:sayHello'/>
       <xs:element name='sayHelloResponse' type='tns:sayHelloResponse'/>
       <xs:complexType name='sayHello'>
       <xs:sequence>
       <xs:element minOccurs='0' name='toWhom' type='xs:string'/>
       </xs:sequence>
       </xs:complexType>
       <xs:complexType name='sayHelloResponse'>
       <xs:sequence>
       <xs:element minOccurs='0' name='return' type='xs:string'/>
       </xs:sequence>
       </xs:complexType>
       </xs:schema>
       </types>
       <message name='HelloWorld_sayHelloResponse'>
       <part element='tns:sayHelloResponse' name='sayHelloResponse'></part>
       </message>
       <message name='HelloWorld_sayHello'>
       <part element='tns:sayHello' name='sayHello'></part>
       </message>
       <portType name='HelloWorld'>
       <operation name='sayHello' parameterOrder='sayHello'>
       <input message='tns:HelloWorld_sayHello'></input>
       <output message='tns:HelloWorld_sayHelloResponse'></output>
       </operation>
       </portType>
       <portType name="portType1"/>
       <binding name='HelloWorldBinding' type='tns:HelloWorld'>
       <soap:binding style='document' transport='http://schemas.xmlsoap.org/soap/http'/>
       <operation name='sayHello'>
       <soap:operation soapAction=''/>
       <input>
       <soap:body use='literal'/>
       </input>
       <output>
       <soap:body use='literal'/>
       </output>
       </operation>
       </binding>
       <service name='HelloWorldWSService'>
       <port binding='tns:HelloWorldBinding' name='HelloWorldPort'>
       <soap:address location='http://192.168.18.101:8080/Quickstart_webservice_consumer_wise/HelloWorldWS'/>
       </port>
       </service>
       <plnk:partnerLinkType name="HelloWorld">
       <plnk:role name="role1" portType="tns:HelloWorld"/>
       </plnk:partnerLinkType>
      </definitions>
      


      I used NetBeans 6 to make bpel file
      <?xml version="1.0" encoding="UTF-8"?>
      <process
       name="newProcess"
       targetNamespace="http://enterprise.netbeans.org/bpel/BpelModule3/DefaultServiceName"
       xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
       xmlns:xsd="http://www.w3.org/2001/XMLSchema"
       xmlns:sxt="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Trace"
       xmlns:sxed="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Editor"
       xmlns:tns="http://enterprise.netbeans.org/bpel/BpelModule3/DefaultServiceName" xmlns:ns0="http://enterprise.netbeans.org/bpel/HelloWorldWSWrapper" xmlns:ns1="http://webservice_consumer_wise/helloworld">
       <import namespace="http://webservice_consumer_wise/helloworld" location="192.168.18.101_8080/Quickstart_webservice_consumer_wise/HelloWorldWS.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
       <partnerLinks>
       <partnerLink name="PartnerLink1" partnerLinkType="ns1:HelloWorld" myRole="role1"/>
       </partnerLinks>
       <variables>
       <variable name="SayHelloOut" xmlns:tns="http://webservice_consumer_wise/helloworld" messageType="tns:HelloWorld_sayHelloResponse"/>
       <variable name="SayHelloIn" xmlns:tns="http://webservice_consumer_wise/helloworld" messageType="tns:HelloWorld_sayHello"/>
       </variables>
       <sequence>
       <receive name="Receive1" partnerLink="PartnerLink1" operation="sayHello" xmlns:tns="http://webservice_consumer_wise/helloworld" portType="tns:HelloWorld" createInstance="yes" variable="SayHelloIn"/>
       <assign name="Assign1">
       <copy>
       <from>$SayHelloIn.sayHello/toWhom</from>
       <to>$SayHelloOut.sayHelloResponse/return</to>
       </copy>
       </assign>
       <reply name="Reply1" partnerLink="PartnerLink1" operation="sayHello" xmlns:tns="http://webservice_consumer_wise/helloworld" portType="tns:HelloWorld" variable="SayHelloOut"/>
       </sequence>
      </process>
      


      I packed it to a zip file and deployed it on jbpm-bpel successful.
      I got a wsdl file on "http://192.168.18.100:8080/newProcess/role1?wsdl"
      <definitions targetNamespace='http://enterprise.netbeans.org/bpel/BpelModule3/DefaultServiceName' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:bindingNS2='http://webservice_consumer_wise/helloworld' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://enterprise.netbeans.org/bpel/BpelModule3/DefaultServiceName'>
       <import location='http://192.168.18.100:8080/newProcess/role1?wsdl&resource=newProcess-binding-1.wsdl' namespace='http://webservice_consumer_wise/helloworld'></import>
       <service name='newProcessService'>
       <port binding='bindingNS2:HelloWorldBinding' name='role1Port'>
       <soap:address location='http://192.168.18.100:8080/newProcess/role1'/>
       </port>
       </service>
      </definitions>
      


      the axis2 client
      import org.netbeans.enterprise.bpel.bpelmodule3.defaultservicename.NewProcessServiceStub;
      
      public class AA {
      
       public static void main(String[] args) throws Exception {
       //WSDL2Java.main(new String[]{"-uri","http://192.168.18.100:8080/newProcess/Role?wsdl"});
       NewProcessServiceStub npss=new NewProcessServiceStub();
       NewProcessServiceStub.SayHelloE sayhe=new NewProcessServiceStub.SayHelloE();
       NewProcessServiceStub.SayHello sayh=new NewProcessServiceStub.SayHello();
       sayh.setToWhom("asfawef");
       sayhe.setSayHello(sayh);
      
       NewProcessServiceStub.SayHelloResponseE shre=npss.sayHello(sayhe);
       NewProcessServiceStub.SayHelloResponse shr=shre.getSayHelloResponse();
       System.out.print(shr.get_return());
      
       }
      
      }
      


      this is the result
      Exception in thread "main" org.apache.axis2.AxisFault: Read timed out
       at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430)
       at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:193)
       at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:75)
       at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:371)
       at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:209)
       at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:448)
       at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:401)
       at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:228)
       at org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
       at org.netbeans.enterprise.bpel.bpelmodule3.defaultservicename.NewProcessServiceStub.sayHello(NewProcessServiceStub.java:183)
       at AA.main(AA.java:18)
      Caused by: java.net.SocketTimeoutException: Read timed out
       at java.net.SocketInputStream.socketRead0(Native Method)
       at java.net.SocketInputStream.read(Unknown Source)
       at java.io.BufferedInputStream.fill(Unknown Source)
       at java.io.BufferedInputStream.read(Unknown Source)
       at org.apache.commons.httpclient.HttpParser.readRawLine(HttpParser.java:78)
       at org.apache.commons.httpclient.HttpParser.readLine(HttpParser.java:106)
       at org.apache.commons.httpclient.HttpConnection.readLine(HttpConnection.java:1116)
       at org.apache.commons.httpclient.MultiThreadedHttpConnectionManager$HttpConnectionAdapter.readLine(MultiThreadedHttpConnectionManager.java:1413)
       at org.apache.commons.httpclient.HttpMethodBase.readStatusLine(HttpMethodBase.java:1973)
       at org.apache.commons.httpclient.HttpMethodBase.readResponse(HttpMethodBase.java:1735)
       at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1098)
       at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398)
       at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)
       at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
       at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346)
       at org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:542)
       at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:189)
       ... 9 more
      


      How can I do that?
      Help~

        • 1. Re: I deploy the bpel file successful, but when I used axis
          HC Kanty Newbie

          192.168.18.101 is my computer 's ip, ping 192.168.18.100 is ok, and all of firewalls are closed.

          when I used , I got the parameter value successful.
          But I want to invoke the sayHello function, I got the "AxisFault: Read timed out " Exception.

          wsdl file

          <definitions name='HelloWorldWSService' targetNamespace='http://webservice_consumer_wise/helloworld' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://webservice_consumer_wise/helloworld' xmlns:xsd='http://www.w3.org/2001/XMLSchema' xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype">
           <types>
           <xs:schema targetNamespace='http://webservice_consumer_wise/helloworld' version='1.0' xmlns:tns='http://webservice_consumer_wise/helloworld' xmlns:xs='http://www.w3.org/2001/XMLSchema'>
           <xs:element name='sayHello' type='tns:sayHello'/>
           <xs:element name='sayHelloResponse' type='tns:sayHelloResponse'/>
           <xs:complexType name='sayHello'>
           <xs:sequence>
           <xs:element minOccurs='0' name='toWhom' type='xs:string'/>
           </xs:sequence>
           </xs:complexType>
           <xs:complexType name='sayHelloResponse'>
           <xs:sequence>
           <xs:element minOccurs='0' name='return' type='xs:string'/>
           </xs:sequence>
           </xs:complexType>
           </xs:schema>
           </types>
           <message name='HelloWorld_sayHelloResponse'>
           <part element='tns:sayHelloResponse' name='sayHelloResponse'></part>
           </message>
           <message name='HelloWorld_sayHello'>
           <part element='tns:sayHello' name='sayHello'></part>
           </message>
           <portType name='HelloWorld'>
           <operation name='sayHello' parameterOrder='sayHello'>
           <input message='tns:HelloWorld_sayHello'></input>
           <output message='tns:HelloWorld_sayHelloResponse'></output>
           </operation>
           </portType>
           <portType name="portType1"/>
           <binding name='HelloWorldBinding' type='tns:HelloWorld'>
           <soap:binding style='document' transport='http://schemas.xmlsoap.org/soap/http'/>
           <operation name='sayHello'>
           <soap:operation soapAction=''/>
           <input>
           <soap:body use='literal'/>
           </input>
           <output>
           <soap:body use='literal'/>
           </output>
           </operation>
           </binding>
           <service name='HelloWorldWSService'>
           <port binding='tns:HelloWorldBinding' name='HelloWorldPort'>
           <soap:address location='http://192.168.18.101:8080/Quickstart_webservice_consumer_wise/HelloWorldWS'/>
           </port>
           </service>
           <plnk:partnerLinkType name="HelloWorld">
           <plnk:role name="role1" portType="tns:HelloWorld"/>
           <plnk:role name="role2" portType="tns:HelloWorld"/>
           </plnk:partnerLinkType>
          </definitions>
          


          bpel file
          <?xml version="1.0" encoding="UTF-8"?>
          <process
           name="newProcess"
           targetNamespace="http://enterprise.netbeans.org/bpel/BpelModule3/DefaultServiceName"
           xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
           xmlns:xsd="http://www.w3.org/2001/XMLSchema"
           xmlns:sxt="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Trace"
           xmlns:sxed="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Editor"
           xmlns:tns="http://enterprise.netbeans.org/bpel/BpelModule3/DefaultServiceName" xmlns:ns0="http://enterprise.netbeans.org/bpel/HelloWorldWSWrapper" xmlns:ns1="http://webservice_consumer_wise/helloworld">
           <import namespace="http://webservice_consumer_wise/helloworld" location="192.168.18.101_8080/Quickstart_webservice_consumer_wise/HelloWorldWS.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
           <partnerLinks>
           <partnerLink name="PartnerLink1" partnerLinkType="ns1:HelloWorld" myRole="role1" partnerRole="role2"/>
           </partnerLinks>
           <variables>
           <variable name="SayHelloOut" xmlns:tns="http://webservice_consumer_wise/helloworld" messageType="tns:HelloWorld_sayHelloResponse"/>
           <variable name="SayHelloIn" xmlns:tns="http://webservice_consumer_wise/helloworld" messageType="tns:HelloWorld_sayHello"/>
           </variables>
           <sequence>
           <receive name="Receive1" partnerLink="PartnerLink1" operation="sayHello" xmlns:tns="http://webservice_consumer_wise/helloworld" portType="tns:HelloWorld" createInstance="yes" variable="SayHelloIn"/>
           <invoke name="Invoke1" partnerLink="PartnerLink1" operation="sayHello" xmlns:tns="http://webservice_consumer_wise/helloworld" portType="tns:HelloWorld" inputVariable="SayHelloIn" outputVariable="SayHelloOut"/>
           <reply name="Reply1" partnerLink="PartnerLink1" operation="sayHello" xmlns:tns="http://webservice_consumer_wise/helloworld" portType="tns:HelloWorld" variable="SayHelloOut"/>
           </sequence>
          </process>
          




          • 2. Re: I deploy the bpel file successful, but when I used axis
            Alejandro Guizar Master

            Do you see any error in the server console?

            • 3. Re: I deploy the bpel file successful, but when I used axis
              HC Kanty Newbie

               

              "alex.guizar@jboss.com" wrote:
              Do you see any error in the server console?


              no error in the server console...
              could you help me?
              could you upload the right files?
              many thanks..