axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "keith chapman" <keithgchap...@gmail.com>
Subject Re: Unable to generate EPR for transport : http
Date Fri, 27 Jun 2008 04:12:38 GMT
The reason you have NPCServiceHttpSoap11Endpoint at the end of the EPR is to
specify the endpoint this request is heading to. Ideally when u generate a
stub for a service it will pick up the EPR from the WSDL. So just doing

YourserviceStub stub = new YourserviceStub();

would send the request to the address defined in the WSDL. What are the
options you used when generating the stub?

Thanks,
Keith.

On Thu, Jun 26, 2008 at 11:35 PM, Attharkar, Asmita <aatthark@telcordia.com>
wrote:

> Thanks a lot Charitha, I could make the call running with no issues.
>
> I have few questions though:
> Why cant I use the default constructor meaning
> YourserviceStub stub = new YourserviceStub();
>
> Since the stub has this particular implementation in the default
> constructor?
>
> public YourserviceStub () throws org.apache.axis2.AxisFault {
> this("http://localhost:8080/axis2/services/NPCWebService" );
> }
>
> Why do I need to include the "NPCServiceHttpSoap11Endpoint"
>
> Also how can I correct the error that it shows (Unable to generate EPR for
> transport : http) when generating the wsdl file.
>
> Thanks,
> Asmita
>
>
> -----Original Message-----
> From: Charitha Kankanamge [mailto:charitha@wso2.com]
> Sent: Thursday, June 26, 2008 1:11 PM
> To: axis-user@ws.apache.org
> Subject: Re: Unable to generate EPR for transport : http
>
> Can you please try to invoke your service by passing the endpoint url in
> the constructor of stub as follows.
>
> YourserviceStub stub = new
> YourserviceStub("http://
> [xxx.xx.172.79]:8080/axis2/services/NPCService.NPCServiceHttpSoap11Endpoint")
>
> regards
> Charitha
>
> Attharkar, Asmita wrote:
>
> >Hi Charitha,
> >
> >Please find my WSDL: - I have edited the location in the end with
> xxx.xx.172.79
> >
> >
> ><wsdl:definitions targetNamespace="http://NPCWebService.telcordia.com">
> ><wsdl:documentation>
> >        This is my first Web service.
> ></wsdl:documentation>
> >−
> >        <wsdl:types>
> >−
> >        <xs:schema attributeFormDefault="qualified"
> elementFormDefault="qualified" targetNamespace="
> http://NPCWebService.telcordia.com/xsd">
> >−
> >        <xs:element name="processNPCMsg">
> >−
> >        <xs:complexType>
> >−
> >        <xs:sequence>
> ><xs:element minOccurs="0" name="string_name" nillable="true"
> type="xs:string"/>
> ><xs:element minOccurs="0" name="string_pwd" nillable="true"
> type="xs:string"/>
> ><xs:element minOccurs="0" name="string_msg" nillable="true"
> type="xs:string"/>
> ></xs:sequence>
> ></xs:complexType>
> ></xs:element>
> ></xs:schema>
> ></wsdl:types>
> >−
> >        <wsdl:message name="processNPCMsgRequest">
> ><wsdl:part name="parameters" element="ns:processNPCMsg"/>
> ></wsdl:message>
> ><wsdl:message name="processNPCMsgResponse"/>
> >−
> >        <wsdl:portType name="NPCServicePortType">
> >−
> >        <wsdl:operation name="processNPCMsg">
> ><wsdl:input message="axis2:processNPCMsgRequest"
> wsaw:Action="urn:processNPCMsg"/>
> ><wsdl:output message="axis2:processNPCMsgResponse"
> wsaw:Action="urn:processNPCMsgResponse"/>
> ></wsdl:operation>
> ></wsdl:portType>
> >−
> >        <wsdl:binding name="NPCServiceSoap11Binding"
> type="axis2:NPCServicePortType">
> ><soap:binding transport="http://schemas.xmlsoap.org/soap/http"
> style="document"/>
> >−
> >        <wsdl:operation name="processNPCMsg">
> ><soap:operation soapAction="urn:processNPCMsg" style="document"/>
> >−
> >        <wsdl:input>
> ><soap:body use="literal"/>
> ></wsdl:input>
> >−
> >        <wsdl:output>
> ><soap:body use="literal"/>
> ></wsdl:output>
> ></wsdl:operation>
> ></wsdl:binding>
> >−
> >        <wsdl:binding name="NPCServiceSoap12Binding"
> type="axis2:NPCServicePortType">
> ><soap12:binding transport="http://schemas.xmlsoap.org/soap/http"
> style="document"/>
> >−
> >        <wsdl:operation name="processNPCMsg">
> ><soap12:operation soapAction="urn:processNPCMsg" style="document"/>
> >−
> >        <wsdl:input>
> ><soap12:body use="literal"/>
> ></wsdl:input>
> >−
> >        <wsdl:output>
> ><soap12:body use="literal"/>
> ></wsdl:output>
> ></wsdl:operation>
> ></wsdl:binding>
> >−
> >        <wsdl:binding name="NPCServiceHttpBinding"
> type="axis2:NPCServicePortType">
> ><http:binding verb="POST"/>
> >−
> >        <wsdl:operation name="processNPCMsg">
> ><http:operation location="NPCService/processNPCMsg"/>
> >−
> >        <wsdl:input>
> ><mime:content type="text/xml" part="processNPCMsg"/>
> ></wsdl:input>
> >−
> >        <wsdl:output>
> ><mime:content type="text/xml" part="processNPCMsg"/>
> ></wsdl:output>
> ></wsdl:operation>
> ></wsdl:binding>
> >−
> >        <wsdl:service name="NPCService">
> >−
> >        <wsdl:port name="NPCServiceHttpSoap11Endpoint"
> binding="axis2:NPCServiceSoap11Binding">
> ><soap:address location="http://
> [xxx.xx.172.79]:8080/axis2/services/NPCService.NPCServiceHttpSoap11Endpoint"/>
> ></wsdl:port>
> >−
> >        <wsdl:port name="NPCServiceHttpSoap12Endpoint"
> binding="axis2:NPCServiceSoap12Binding">
> ><soap12:address location="http://
> [xxx.xx.172.79]:8080/axis2/services/NPCService.NPCServiceHttpSoap12Endpoint"/>
> ></wsdl:port>
> >−
> >        <wsdl:port name="NPCServiceHttpEndpoint"
> binding="axis2:NPCServiceHttpBinding">
> ><http:address location="http://
> [xxx.xx.172.79]:8080/axis2/services/NPCService.NPCServiceHttpEndpoint"/>
> ></wsdl:port>
> ></wsdl:service>
> ></wsdl:definitions>
> >
> >
> >
> >
> >
> >-----Original Message-----
> >From: Charitha Kankanamge [mailto:charitha@wso2.com]
> >Sent: Thursday, June 26, 2008 11:52 AM
> >To: axis-user@ws.apache.org
> >Subject: Re: Unable to generate EPR for transport : http
> >
> >Hi Asmita,
> >Can you post your wsdl please?
> >
> >regards
> >Charitha
> >
> >Attharkar, Asmita wrote:
> >
> >
> >
> >>Hi, Please find my services.xml in regards to the issue I am having
> >>
> >><service targetNamespace="http://NPCWebService.telcordia.com">
> >>
> >><schema schemaNamespace="http://NPCWebService.telcordia.com/xsd"/>
> >>
> >><Description>
> >>
> >>This is my first Web service.
> >>
> >></Description>
> >>
> >><parameter name="ServiceClass" locked="false">
> >>
> >>com.telcordia.test.ws.NPCWebService
> >>
> >></parameter>
> >>
> >><operation name="processNPCMsg">
> >>
> >><messageReceiver
> >>class="org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver"/>
> >>
> >></operation>
> >>
> >><transports>
> >>
> >><transport>http</transport>
> >>
> >></transports>
> >>
> >></service>
> >>
> >>Thanks,
> >>
> >>Asmita
> >>
> >>------------------------------------------------------------------------
> >>
> >>*From:* Attharkar, Asmita [mailto:aatthark@telcordia.com]
> >>*Sent:* Wednesday, June 25, 2008 11:49 AM
> >>*To:* 'axis-user@ws.apache.org'
> >>*Subject:* Unable to generate EPR for transport : http
> >>
> >>Hi there,
> >>
> >>I am using JRE and JDK 1.5_15, I am using ant 1.6, apache tomcat
> >>server 1.6 and Axis2 1.4.
> >>
> >>Eclipse plugins are not available for Axis2 1.4, the latest plugin
> >>available is Axis2 1.2 for Eclipse, Hence I am ant tasks for the
> >>general operations through build.xml
> >>
> >>When I try to generate the wsdl file using the java2wsdl tool – I get
> >>this error saying "Unable to generate EPR for the transport : http"
> >>
> >>But when I deploy the aar file it gets deployed with no issues. My aar
> >>file does not have any wsdl file.
> >>
> >>Now when I use the stub which is created out the wsdl file generated
> >>with java2wsdl tool(Though the file is created with an error "Unable
> >>to generate EPR for the transport : http"). The client when tries to
> >>go through this stub to access the service deployed – Its gets the error:
> >>
> >>org.apache.axis2.AxisFault: The service cannot be found for the
> >>endpoint reference (EPR)
> >>http://localhost:8080/axis2/services/NPCWebService
> >>
> >>at org.apache.axis2.engine.DispatchPhase.checkPostConditions(DispatchPha
> >>
> >>se.java:64)
> >>
> >>Any help is greatly appreciated.
> >>
> >>Thanks,
> >>
> >>Asmita
> >>
> >>------------------------------------------------------------------------
> >>
> >>No virus found in this incoming message.
> >>Checked by AVG.
> >>Version: 7.5.524 / Virus Database: 270.4.1/1517 - Release Date: 6/24/2008
> 8:41 PM
> >>
> >>
> >>
> >>
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> >For additional commands, e-mail: axis-user-help@ws.apache.org
> >
> >
> >
> >------------------------------------------------------------------------
> >
> >No virus found in this incoming message.
> >Checked by AVG.
> >Version: 7.5.524 / Virus Database: 270.4.1/1517 - Release Date: 6/24/2008
> 8:41 PM
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


-- 
Keith Chapman
Senior Software Engineer
WSO2 Inc.
Oxygenating the Web Service Platform.
http://wso2.org/

blog: http://www.keith-chapman.org
Mime
View raw message