Generating proxies from WSDL utility

Hey ..
Does BEA give a utility to generate client webservice proxy classes from a WSDL
I mean ..instead of any server classes to run clientgen..I have just the WSDL
and I need to generate the proxy classes for myself..I guess it defeats the purpose
of webservices(integration)..if I have to ask the webservice deployer for client
classes ..!
Thanx,
Krish

"Krishnan Venkataraman" <[email protected]> wrote in message
news:[email protected]...
>
Manoj , u sure this is a valid link ...coz I cannot see a wsdl athttp://example.com/myapp/myservice.wsdl..
This should be the url to your wsdl. (the wsdl from which you want
to generate the service). You can also copy the wsdl to your local
machine and use the file url.
>
and is there any WLS70 dependency for me to generate these proxies ...Imean do
I need anything from WLS70 (jar files etc)for me to do this task ...?You need wls70. the clientgen ant task is provided by wls70.
>
BTW.. just to update u on our other issue we talked about...have a look atthe
below trace...Thanx,Krish
Shridhar ...
Couple of things ...
1) We will ask the webservice provider put the CR080927_70sp1.jar intheir classpath.
But instead of they generating the client-jar and runningVersionMaker on
this to give us the output , can we do this on ourside...
I understand that there is a way in which the client itself generatestheir
own proxies from the wsdl...In case we can do this ...isCR080927_70sp1.jar required
on
the client side also for generating the proxies...or is it required onthe
WLS70 side only at runtime...once we generate these proxies ourselves thenfor
compiling our 6.0 client and running it , I will use the output ofversionMaker
and wsclient70.jar.
2) Can u possibly mail me the patched jar files which u mention below byemail...and
send me a confirmation email saying u have sent it..coz we seem to havesome firewall
issues going to an outside ftpserver....and the confirmation mail is onlyincase
u send the mail and I do not get it coz of the size etc ..
Thanx,
Krish
Krishnan (Krish) Venkataraman
Bank of America Corp.
Senior Technology Analyst
Email: [email protected]
Work # : 646 733 4248
Cell # : 646 210 5482
-----Original Message-----
From: Shridhar Mysore [mailto:[email protected]]
Sent: Friday, November 01, 2002 12:38 PM
To: Venkataraman, Krishnan
Subject: Invoking 7.0 WS from 6.0 WS client [ Case 367229 ]
Hello Krishnan,
Firstly, your present configuration (involving the use of a SessionBeanin 6.0sp1
as WS client calling into a WS hosted in 7.0sp1) where you are using 7.0webserviceclient.jar
alongside 6.0 weblogic.jar is not supported, nay non-viable. The result ofsuch
a configuration would lead to NoSuchMethodError exceptions which you haveseen
at your end.
Secondly, in order to solve this we need to use portable stubs for WSclients,
a feature, that has been included in
7.0 SP02 ! We, however have made this feature available on 7.0 SP01 aswell in
the form of a one-off patch !
And the following is a procedure for enabling this on 7.0SP01 :
- Add the one-off patch ( CR080927_70sp1.jar ) at the beginning of theCLASSPATH
in your 7.0 server startup script. Ensure that you restart the server forthis
to kick in.
- Generate the client jar for the 7.0 WS
- Run the weblogic.webservice.tools.versioning.VersionMaker utility bysupplying
the client jar to generate re-versioned classes.
- Compile the WS client in 6.0 by supplying the re-versioned classes(generated
from VersionMaker ) and wsclient70.jar (note wsclient70.jar should workwith
6.x versions)
- Run the WS client in 6.0 by supplying the re-versioned classes(generated from
VersionMaker ) and wsclient70.jar
Lastly, please find/download the following files from our FTP server(ftpsupport.beasys.com)
at /pub/case367229
by logging in with username/password as support/pechool
( Note : this password is valid for the week of Oct 27, 2002 )
CR080927_70sp1.jar - one-off patch for 7.0sp01
wsclient70.jar - this would be used instead ofwebserviceclient.jar by
6.x WS client/s
"manoj cheenath" <[email protected]> wrote:
Sure. you can generate client from a WSDL.
Please try this:
<clientgen wsdl="http://example.com/myapp/myservice.wsdl"
packageName="myapp.myservice.client"
clientJar="c:/myapps/myService_client.jar"/>
regards,
-manoj
"Krishnan Venkataraman" <[email protected]> wrote in message
news:[email protected]...
Hey ..
Does BEA give a utility to generate client webservice proxy classesfrom a
WSDL
I mean ..instead of any server classes to run clientgen..I have justthe
WSDL
and I need to generate the proxy classes for myself..I guess it defeatsthe purpose
of webservices(integration)..if I have to ask the webservice deployerfor
client
classes ..!
Thanx,
Krish

Similar Messages

  • IWAB0399E Error in generating Java from WSDL:  java.lang.RuntimeException:

    Hi,
    I did try to create web service client using eclipse. Imported wsdl to eclipse project and tried to create java client but I am getting following exception :
    IWAB0399E Error in generating Java from WSDL: java.lang.RuntimeException: Unknown element _value
    java.lang.RuntimeException: Unknown element _value
    at org.apache.axis.wsdl.toJava.JavaBeanWriter.getBinaryTypeEncoderName(JavaBeanWriter.java:490)
    at org.apache.axis.wsdl.toJava.JavaBeanWriter.writeSimpleTypeGetter(JavaBeanWriter.java:928)
    at org.apache.axis.wsdl.toJava.JavaBeanWriter.writeAccessMethods(JavaBeanWriter.java:1102)
    at org.apache.axis.wsdl.toJava.JavaBeanWriter.writeFileBody(JavaBeanWriter.java:238)
    at org.apache.axis.wsdl.toJava.JavaWriter.generate(JavaWriter.java:127)
    at org.apache.axis.wsdl.toJava.JavaBeanWriter.generate(JavaBeanWriter.java:1405)
    at org.apache.axis.wsdl.toJava.JavaTypeWriter.generate(JavaTypeWriter.java:113)
    at org.apache.axis.wsdl.toJava.JavaGeneratorFactory$Writers.generate(JavaGeneratorFactory.java:421)
    at org.apache.axis.wsdl.gen.Parser.generateTypes(Parser.java:547)
    at org.apache.axis.wsdl.gen.Parser.generate(Parser.java:432)
    at org.apache.axis.wsdl.gen.Parser.access$000(Parser.java:45)
    at org.apache.axis.wsdl.gen.Parser$WSDLRunnable.run(Parser.java:362)
    at java.lang.Thread.run(Unknown Source)
    This works just fine in SoapUI. Also can access this from other clients.
    You can access the wsdl fine from http://unit7165.oracleads.com:9008/opptyMgmtOpportunities/OpportunityService?wsdl
    Does anybody know why this does not work in Eclipse?
    Thanks.

    Hi Team,
    I am too getting same exception when trying to create client side code from wsdl.
    Below is what I am using :
    wsdl link :
    https://fap0607-crm.oracleads.com/mklLeads/SalesleadService?wsdl
    Tools I used : Apache Axis 1.4 jars and used command - wsdl2java
    I guess, it's a bug already reported here :
    https:/issues.apache.org/jira/browse/AXIS-1828
    Any pointer to this will help.
    Regards,
    Sumit

  • Re-Generate java from wsdl

    Hello. I have a WSDL that I have generated some Java classes for. In the generated classes I code some helper methods. Then I do a change in the WSDL. Then I need to generate new Java classes(?). How about my helper methods then? I don't want to re-implement them in the newly generated classes.
    And BTW, if I try to run "Regenerate Web Service from WSDL" (right-click the web service in jDeveloper project), I get a message "The return type xxx.yyy.Zzz of method getZzz cannot be serialized into XML, and no custom serializer has been defined for it". What does this message mean, and how can I be able to "Regenerate Web Service from WSDL" (if the WSDL changes).
    I'll be happy for any articles about this topics.

    Hi,
    when you say that you generate Java classes for a WSDL file, I assume you generate a Web Service proxy - am I right? In this case I suggest to create wrapper classes for those that you want to add your custom code in. E.g the proxy class is re-generated, whereby all custom code gets lost. Instead of working with the proxy class directly, you create a Java Bean that accesses the proxy class. This then never changes.
    Frank

  • SAXException while generating stubs from WSDL

    Hi Friends
    i am stuck in a problem for which i need your help.
    i am using the Axis wsdl2java tool to generate the client side stub classes.
    the wsdl which i was using was referring to the port http://localhost/hth/services/Client?wsdl
    i was running the wsdl2java tool on this wsdl to generate stubs. it was working fine.
    Now i have removed the client.wsdl from the default localhost port and
    want to keep it in some location like D:\wsdl\Client.wsdl so that i don't need to depend on the Application server everytime for the wsdl to be up all the time.
    when i run the wsdl2java command on this location i get the following error.
    org.xml.sax.SAXException: Fatal Error: URI=file:///D:/wsdl/Client.wsdl Line=1: The processing instruction target matching "[xX][mM][lL]" is not allowed.
         at org.apache.axis.utils.XMLUtils$ParserErrorHandler.fatalError(XMLUtils.java:723)
         at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:218)
         at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:386)
         at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:316)
         at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1438)
         at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanPIData(XMLScanner.java:689)
         at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanPIData(XMLDocumentFragmentScannerImpl.java:750)
         at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanPI(XMLScanner.java:664)
         at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDispatcher.dispatch(XMLDocumentScannerImpl.java:845)
         at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:368)
         at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:834)
         at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)
         at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)
         at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:250)
         at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:292)
         at org.apache.axis.utils.XMLUtils.newDocument(XMLUtils.java:369)
         at org.apache.axis.utils.XMLUtils.newDocument(XMLUtils.java:420)
         at org.apache.axis.wsdl.symbolTable.SymbolTable.populate(SymbolTable.java:482)
         at org.apache.axis.wsdl.gen.Parser$WSDLRunnable.run(Parser.java:361)
         at java.lang.Thread.run(Thread.java:595)
    Please let me know what is the problem here and how can i resolve this issue.
    here is bit of the sample client.wsdl
    <?xml version="1.0" encoding="UTF-8" ?>
    - <wsdl:definitions targetNamespace="D:\wsdl\Client.wsdl" xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="D:\wsdl\Client.wsdl" xmlns:intf="D:\wsdl\Client.wsdl" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns1="D:\wsdl\Client.wsdl" xmlns:tns2="http://client.hth.march.com" xmlns:tns3="http://exception.hth.march.com" xmlns:tns4="http://equipment.hth.march.com" xmlns:tns5="http://equipment.ws.hth.march.com" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    - <!--
    WSDL created by Apache Axis version: 1.3
    Built on Oct 05, 2005 (05:23:37 EDT)
    -->
    - <wsdl:types>
    - <schema targetNamespace="D:\wsdl\Client.wsdl" xmlns="http://www.w3.org/2001/XMLSchema">
    <import namespace="http://equipment.ws.hth.march.com" />
    <import namespace="http://xml.apache.org/xml-soap" />
    <import namespace="http://exception.hth.march.com" />
    <import namespace="http://client.hth.march.com" />
    <import namespace="http://equipment.hth.march.com" />
    <import namespace="http://localhost/hth/services/Client" />
    <import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
    - <complexType name="HTHBaseDTO">
    - <sequence>
    <element name="md5Sum" nillable="true" type="xsd:string" />
    <element name="primaryKey" nillable="true" type="xsd:integer" />
    </sequence>
    </complexType>
    - <complexType name="VitalThresholdEnum">
    - <sequence>
    <element name="labelKey" nillable="true" type="xsd:string" />
    <element name="pk" nillable="true" type="xsd:short" />
    </sequence>
    </complexType>
    - <complexType name="VitalThresholdDTO">
    - <complexContent>
    - <extension base="tns1:HTHBaseDTO">
    - <sequence>
    <element name="categoryPk" nillable="true" type="xsd:short" />
    <element name="clientCarePlanPk" nillable="true" type="xsd:long" />
    <element name="clientPk" nillable="true" type="xsd:integer" />
    <element name="clientVitalPrescriptionPk" nillable="true" type="xsd:integer" />
    <element name="statusPk" nillable="true" type="xsd:short" />
    <element name="syncStatusPk" nillable="true" type="xsd:short" />
    <element name="thresholdType" nillable="true" type="tns1:VitalThresholdEnum" />
    <element name="thresholdValue" nillable="true" type="xsd:double" />
    <element name="unitTy
    hoping for positive replies from your side.
    Thanks & regards
    Vikram K

    So what was the problem? I am getting:
    error: invalid element "{http://java.sun.com/jax-rpc-ri/xrpcc-config}configuration" in configuration file (line 3)
    and I copied my config.xml from an example on xrpcc site!

  • Generate Proxy from WSDL with multiple Files

    I need to load a WSDL (to generate a web service consumer proxy). However, that WSDL is build from multiple files, both .wsdl and .xsd, not a single one. It seems the SAP wizard to generate the proxy does expect one single WSDL file however.
    Is there a way in SAP to load a WSDL with multiple files, or do I need to (manually) flatten all these files into one single file?

    I am not sure why it fails in WebSphere. Please try posting
    this question to a WebSphere newsgroup.
    Regards,
    -manoj
    http://manojc.com
    "viswanath" <[email protected]> wrote in message
    news:40aee7fa$1@mktnews1...
    >
    thanks manoj for your reply.
    I'm using IBM WebSphere SDK for Web Services v5.1
    for generation of java client.
    I'm able to generate the client but the problem is
    the WSDl2Java command ignored the SOAPHeaders while
    generating the proxy. Since I'm using SOAP headers for
    authentication the code fails.
    Thanks,
    Viswanath
    "manoj cheenath" <[email protected]> wrote:
    I am not sure which tool you are using
    to generate web service clent. To generate
    a WLS web service client you have to use clientgen.
    Details here:
    http://e-docs.bea.com/wls/docs81/webserv/anttasks.html
    Regards,
    -manoj
    http://manojc.com
    "viswanath" <[email protected]> wrote in message
    news:40ad8a07$[email protected]..
    HI,
    I have a web service (implemented in .NET) which extends soap headersfor
    doing
    Authentication. WSDL is generated out of this web service. But wheni use
    wsdl2java
    (J2EE) to generate a proxy class, there is no interface generated forsoap
    headers.
    Without extending SOAP headers the web service works fine.
    Basically, I'm looking for a way to generate java interfaces (ie.
    proxies)
    for
    SOAP headers out of the WSDL file.
    PFA the WSDL file and the proxy
    Any help on this is appreciated.

  • Using oc4j to generate interfaces from wsdl produced improper method names

    The method names that were produced from the opperations in my WSDL, generated an interface file with incorrect method names. The name went from "DoTest" in the wsdl to "doTest" in the Interface file.
    I double checked and all the cases are correct in the wsdl.
    <?xml version="1.0" encoding="UTF-8"?>
    <!-- edited with XMLSpy v2005 rel. 3 U (http://www.altova.com) by John Reynolds (MedPlus) -->
    <definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:y="http://localhost/TestService" targetNamespace="http://localhost/TestService">
         <types>
              <xs:schema targetNamespace="http://localhost/TestService" xmlns="http://www.w3.org/2001/XMLSchema">
                   <xs:element name="Tresult" type="xs:string"/>
                   <xs:element name="Tname" type="xs:string"/>
                   <xs:element name="Tfault" type="xs:string"/>
              </xs:schema>
         </types>
         <message name="DoTestResponse">
              <part name="Result" element="y:Tresult"/>
         </message>
         <message name="DoTestRequest">
              <part name="Name" element="y:Tname"/>
         </message>
         <message name="DoTestFault">
              <part name="ExceptionDetail" element="y:Tfault"/>
         </message>
         <portType name="TestService">
              <operation name="DoTest">
                   <input message="y:DoTestRequest"/>
                   <output message="y:DoTestResponse"/>
                   <fault name="DoTestException" message="y:DoTestFault"/>
              </operation>
         </portType>
         <binding name="TestService" type="y:TestService">
              <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
              <operation name="DoTest">
                   <soap:operation soapAction="urn:#DoTest" style="document"/>
                   <input>
                        <soap:body use="literal"/>
                   </input>
                   <output>
                        <soap:body use="literal"/>
                   </output>
                   <fault name="DoTestException">
                        <soap:fault name="DoTestException" use="literal"/>
                   </fault>
              </operation>
         </binding>
         <service name="TestServiceSoap">
              <port name="TestService" binding="y:TestService">
                   <soap:address location="http://localhost/TestService"/>
              </port>
         </service>
    </definitions>

    Obviously one could rename the operation to that standard, but that doesn't exactly strike me as being anything other that a work around for a bug.
    WSDL provides a contract in which multiple languages have to conform to a set of interfaces, and it's not exactly good to have a tool, just a assume the contract for an interface is wrong.
    I could argue that I'm only doing Java on the front end and .Net on the client side and that they don't neccessarily follow the Java convention, nor should be constrained by it.
    I do agree with you that they probably just followed the convention when writing to code generator and just happened to pick up the convention. They just need to fix it now.

  • Using WSDL2java to generate proxy from wsdl

    HI,
    I have a web service (implemented in .NET) which extends soap headers for doing
    Authentication. WSDL is generated out of this web service. But when i use wsdl2java
    (J2EE) to generate a proxy class, there is no interface generated for soap headers.
    Without extending SOAP headers the web service works fine.
    Basically, I'm looking for a way to generate java interfaces (ie. proxies) for
    SOAP headers out of the WSDL file.
    PFA the WSDL file and the proxy
    Any help on this is appreciated.
    [WSOClient.zip]

    I am not sure why it fails in WebSphere. Please try posting
    this question to a WebSphere newsgroup.
    Regards,
    -manoj
    http://manojc.com
    "viswanath" <[email protected]> wrote in message
    news:40aee7fa$1@mktnews1...
    >
    thanks manoj for your reply.
    I'm using IBM WebSphere SDK for Web Services v5.1
    for generation of java client.
    I'm able to generate the client but the problem is
    the WSDl2Java command ignored the SOAPHeaders while
    generating the proxy. Since I'm using SOAP headers for
    authentication the code fails.
    Thanks,
    Viswanath
    "manoj cheenath" <[email protected]> wrote:
    I am not sure which tool you are using
    to generate web service clent. To generate
    a WLS web service client you have to use clientgen.
    Details here:
    http://e-docs.bea.com/wls/docs81/webserv/anttasks.html
    Regards,
    -manoj
    http://manojc.com
    "viswanath" <[email protected]> wrote in message
    news:40ad8a07$[email protected]..
    HI,
    I have a web service (implemented in .NET) which extends soap headersfor
    doing
    Authentication. WSDL is generated out of this web service. But wheni use
    wsdl2java
    (J2EE) to generate a proxy class, there is no interface generated forsoap
    headers.
    Without extending SOAP headers the web service works fine.
    Basically, I'm looking for a way to generate java interfaces (ie.
    proxies)
    for
    SOAP headers out of the WSDL file.
    PFA the WSDL file and the proxy
    Any help on this is appreciated.

  • Service Control Not Being Generated Correctly from WSDL

    Hello,
    I am using BEA Workshop for WebLogic Platform 9.2.0 for development. I created a web service in Workshop, which exposes 3 methods... one of the methods, putPlan(), accepts two parameters.
    After generating the WSDL from the web service class, I ran the Web Service Client Wizard. I was able to successfully access and test the web service with the generated client code.
    However, in another project, I generated a service control from the WSDL. Although the service control was created without any errors, the control itself does not appear to be correct: it defines the putPlan() method as accepting only one parameter instead of the expected two.
    The WSDL itself looks good, as it clearly defines two input parameters to the putPlan() method. And, the Web Service Client wizard had no problems generating valid client code from the WSDL. So, I am confused as to why the generated service control is not right.
    Any help with this problem would be greatly appreciated.
    Thanks!

    Hi Debbie,
    When you created the service control did you choose the option to generate xmlbean types for the service or did you generate jax/rpc types ?
    Can you send the service, wsdl and control to me via email at akraj_at_yahoo.com ?
    cheers
    Raj

  • Clientgen issues wihile generating clientjar from wsdl

    Hi,
    Iam trying to generate client stubs from the wsdl file using ant clientgen
    Iam getting the following error while building.
    <weblogic.webservice.tools.build.WSBuildException: unable to find any soap port:><service name="SomeWebServic
    e">
    <port name="SomeWebServicePort"
    binding="tns:PSIVzWebServicePort">
    <soap:address location=" http://localhost:7001/somewebservice/SomeWebService">
    </soap:address>
    </port>
    </service> - with nested exception:
    [weblogic.webservice.tools.wsdlp.WSDLParseException: unable to find any soap por
    t:<service name="SomeWebServic
    e">
    <port name="SomeWebServicePort"
    binding="tns:PSIVzWebServicePort">
    <soap:address location=" http://localhost:7001/somewebservice/SomeWebService">
    </soap:address>
    </port>
    </service>
    Does anybodu know what could be the reason. The service has user defined data types.
    Appriciated if anybody can send me the reply with the solution
    Regards
    Manikyala                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    This issue was resolved by compiling with the new wsdl. The old one has some formatiing issues.
    Regards
    Manikyala

  • Generating proxy from wsdl ends in error

    Our sap installation is 'SAP ECC 6.0' and I'm trying to generate proxy (for testing purposes) from se80 by using url: http://cheeso.members.winisp.net/books/books.asmx?WSDL
    Proxy generationg is cancelled by the system and I get message in se80 saying:
    'Exception occurred in library handler
    Not implemented'
    This was working earlier on our system (older sap release) and I also tested this on other sap (SAP ERP Central Component 5.0) and it works.
    Does anyone have an idea, what is wrong?

    I am facing the same problem.
    Take a look at
    https://websmp130.sap-ag.de/sap(bD1lcyZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=748781
    https://websmp130.sap-ag.de/sap(bD1lcyZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=809792
    They correspond to : note 748781 and 809792 in SAP Service Marketplace
    The XML format for proxy generation : note 944029
    I hope it helps you.

  • Xrpcc: Generate stub from WSDL

    Hi,
    I created a JAX-RPC based web services and used xrpcc tool to generate the server-side classes and wsdl file. And then deployed them on tomcat successfully.
    To access the web service, the remote client needs to get the wsdl document (in this case, i used the one generated by the xrpcc tool on the service side) and generate the client-side stub and other classes.
    However, i got an error message when trying to generate the stub:
    error: modeler error: invalid entity name: "PriceQuote" (in namespace: "http://www.w3.org/2001/XMLSchema")
    The wsdl document looks as follows:
    <?xml version="1.0" encoding="UTF-8"?>
    <definitions name="TestService" targetNamespace="http://www.deitel.com/test.wsdl" xmlns:tns="http://www.deitel.com/test.wsdl" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
    <message name="getPrice">
    <part name="String_1" type="xsd:string"/></message>
    <message name="getPriceResponse">
    <part name="result" type="xsd:PriceQuote"/></message>
    <portType name="Test">
    <operation name="getPrice">
    <input message="tns:getPrice"/>
    <output message="tns:getPriceResponse"/></operation></portType>
    <binding name="TestBinding" type="tns:Test">
    <operation name="getPrice">
    <input>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" use="encoded" namespace="http://www.deitel.com/test.wsdl"/></input>
    <output>
    <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" use="encoded" namespace="http://www.deitel.com/test.wsdl"/></output>
    <soap:operation soapAction=""/></operation>
    <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"/></binding>
    <service name="TestService">
    <port name="TestPort" binding="tns:TestBinding">
    <soap:address location="http://zhang:8080/jaxrpc-test/test/endpoint/Test"/></port></service></definitions>
    I noticed that the error is caused by PriceQuote data type. Then I added PriceQuote data type definition to the wsdl file.
    <types>
    <xsd:schema
    targetNamespace="http://www.deitel.com/schema"
    xmlns="http://www.w3.org/2001/XMLSchema">
    <xsd:complexType name="PriceQuote">
    <xsd:sequence>
    <xsd:element name="price" type="xsd:double"/>
    <xsd:element name="ISBN" type="xsd:string"/>
    <xsd:element name="storeID" type="xsd:int"/>
    <xsd:element name="storeDescription" type="xsd:string"/>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:schema>
    </types>
    <message name="getPrice">
    <part name="String_1" type="xsd:string"/></message>
    <message name="getPriceResponse">
    <part name="result" type="xsd1:PriceQuote"/></message>
    The xrpcc tool then can generate the client-side stub and classes without any problems. However, when the client is executed, I got the following error message:
    java.rmi.RemoteException: deserialization error: deserialization error: deserial
    ization error: deserialization error: unexpected element type: expected={http://
    www.deitel.com/schema}PriceQuote, actual={http://www.w3.org/2001/XMLSchema}Price
    Quote; nested exception is:
    deserialization error: deserialization error: deserialization error: des
    erialization error: unexpected element type: expected={http://www.deitel.com/sch
    ema}PriceQuote, actual={http://www.w3.org/2001/XMLSchema}PriceQuote
    deserialization error: deserialization error: deserialization error: deserialization error: unexpected element type: expected={http://www.deitel.com/schema}PriceQuote, actual={http://www.w3.org/2001/XMLSchema}PriceQuote
    at com.sun.xml.rpc.encoding.SOAPDeserializationContext.deserializeMultiR
    efObjects(SOAPDeserializationContext.java:107)
    at com.sun.xml.rpc.client.StreamingSender._sendStreamingSender.java:159)
    at test.TestPort_Stub.getPrice(Unknown Source)
    Any suggestions?
    Thanks in advance,
    Su

    Su,
    I have been having same problem you have experimented. I did not quite understand the change you made exactly. Can you please help.
    Thanks
    Sam
    <?xml version="1.0"?>
    <definitions
    name="stockquote"
    targetNamespace="http://quote.com/stockquote.wsdl"
    xmlns:tns="http://quote.com/stockquote.wsdl"
    xmlns:xsd1="http://quote.com/stockquote.xsd"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns="http://schemas.xmlsoap.org/wsdl/">
    <types>
    <schema targetNamespace="http://quote.com/stockquote.xsd"
    xmlns="http://www.w3.org/2000/10/XMLSchema">
    <element name="TradePriceRequest">
    <complexType>
    <all>
    <element name="tickerSymbol" type="string"/>
    </all>
    </complexType>
    </element>
    <element name="TradePrice">
    <complexType>
    <all>
    <element name="price" type="float"/>
    </all>
    </complexType>
    </element>
    </schema>
    </types>
    <message name="GetLastTradePriceInput">
    <part name="body" element="xsd1:TradePriceRequest"/>
    </message>
    <message name="GetLastTradePriceOutput">
    <part name="body" element="xsd1:TradePrice"/>
    </message>
    <portType name="StockQuotePortType">
    <operation name="GetLastTradePrice">
    <input message="tns:GetLastTradePriceInput"/>
    <output message="tns:GetLastTradePriceOutput"/>
    </operation>
    </portType>
    <binding name="StockQuoteSoapBinding" type="tns:StockQuotePortType">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="GetLastTradePrice">
    <soap:operation soapAction="http://quote.com/GetLastTradePrice"/>
    <input>
    <soap:body use="literal"/>
    </input>
    <output>
    <soap:body use="literal"/>
    </output>
    </operation>
    </binding>
    <service name="StockQuoteService">
    <documentation>My first service</documentation>
    <port name="StockQuotePort" binding="tns:StockQuoteBinding">
    <soap:address location="http://quote.com/stockquote"/>
    </port>
    </service>
    </definitions>
    Hi Todor,
    I found out what caused the problem: I used
    "http://www.w3.org/2001/XMLSchema" as the
    typeNameSpace in the configuration file that is passed
    into the xrpcc tool when generates the wsdl document.
    Once I changed it to something else, everything works
    fine.
    Thanks,
    Su

  • How To Generate XSL for integration from WSDL

    Hi,
    Can anybody help me to how to generate XSL from WSDL file for Integration.....
    Thanks

    You can use Oracle JDeveloper to general XSL against WSDL or some XML tool like XML Spy. There are lots of XSL tools available to do this (some embedded in Eclipse we well)

  • How to generate class files from wsdl

    I have upgraded weblogic from 9.1 to 10.3.5 and java from 1.5.0_06 to 1.6.0_27
    Do I have to regenerate my webservices classes like the stub ,impl and service class.
    also there are a few changes in the wsdl .
    Please help me how to generate classfiles from wsdl ?
    Please help.
    Thanks,

    Did you ever get an answer to this question? Did you proceed forward with the use of WSIF or did you select an alternative.
    Ernie :)

  • Weblogic 8.1 :: Getting error while generating Client java class from WSDL

    Hi,
    For SOAP webservice, I am using ant script to generate java client from WSDL but getting below error. Please inform if any suggestion to resolve this.
    Also let me know if any other alternative to generate client java code.
    Ant script:
    ===========
    <project name="project" default="generateClientJar">
         <property file="build.property">
         </property>
         <taskdef name="clientgen" classname="weblogic.ant.taskdefs.webservices.clientgen.ClientGenTask">
              <classpath>
                   <fileset dir="${build_lib.dir}" includes="*.jar" />
              </classpath>
         </taskdef>
         <path id="compile_path">
              <pathelement location="C:/jar/wls-api.jar" />
              <pathelement location="${build_lib.dir}/weblogic.jar" />
              <pathelement location="C:/jar/webserviceclient+ssl.jar" />
              <pathelement location="D:/Java_Src_10.1.0/nextgen_arch/wlpatch/webservices.jar" />
         </path>
         <target name="generateClientJar" depends="generate.client">
    <clientgen wsdl="${wsdl.file}" classpathref="compile_path"
    serviceName="${service.name}"
    packageName= "${client.pkg}"
    clientJar="${ws.client.name}" />
         </target>
         <target name="generate.client" description="Generate web-services client">
              <property name="wsdl.file" value="${sms.wsdl.file}"/>
              <property name="client.pkg" value="${sms.client.pkg}"/>
              <property name="ws.client.name" value="${ws.sms.name}"/>
              <property name="service.name" value="${sms.service.name}"/>
         </target>
    </project>
    build.property file
    ===========
    base=C:/SMS
    lib=E:/jar_path
    sms.wsdl.file=${base}/SMS.wsdl
    sms.client.pkg=com.db.dbdi.gtbportal.sms.client     
    ws.sms.name=${lib}/ws_SmsService_client.jar
    sms.service.name=SMSService
    build_lib.dir = E:/jar_path
    Error log:
    ================
    Buildfile: D:\Java_Src_10.1.0\ant\build_weblogic8.xml
    generate.client:
    generateClientJar:
    [clientgen] Generating client jar for C:/SMS/SMS.wsdl ...
    [clientgen] C:\Documents and Settings\amitkumar.patel\Local Settings\Temp\ws_SmsService_client.jar699419996\com\db\dbdi\gtbportal\sms\client\SMSPort.java:15: parameters is already defined in sendSMS(com.db.portal.webservices.sms.SendSMS,com.db.portal.webservices.sms.holders.SendSMSResponseHolder)
    [clientgen] public void sendSMS(com.db.portal.webservices.sms.SendSMS parameters, com.db.portal.webservices.sms.holders.SendSMSResponseHolder parameters)
    [clientgen] ^
    [clientgen] C:\Documents and Settings\amitkumar.patel\Local Settings\Temp\ws_SmsService_client.jar699419996\com\db\dbdi\gtbportal\sms\client\SMSPort.java:21: parameters is already defined in getStatus(com.db.portal.webservices.sms.GetStatus,com.db.portal.webservices.sms.holders.GetStatusResponseHolder)
    [clientgen] public void getStatus(com.db.portal.webservices.sms.GetStatus parameters, com.db.portal.webservices.sms.holders.GetStatusResponseHolder parameters)
    [clientgen] ^
    [clientgen] C:\Documents and Settings\amitkumar.patel\Local Settings\Temp\ws_SmsService_client.jar699419996\com\db\dbdi\gtbportal\sms\client\SMSPort_Stub.java:20: parameters is already defined in sendSMS(com.db.portal.webservices.sms.SendSMS,com.db.portal.webservices.sms.holders.SendSMSResponseHolder)
    [clientgen] public void sendSMS(com.db.portal.webservices.sms.SendSMS parameters, com.db.portal.webservices.sms.holders.SendSMSResponseHolder parameters)
    [clientgen] ^
    [clientgen] C:\Documents and Settings\amitkumar.patel\Local Settings\Temp\ws_SmsService_client.jar699419996\com\db\dbdi\gtbportal\sms\client\SMSPort_Stub.java:39: parameters is already defined in getStatus(com.db.portal.webservices.sms.GetStatus,com.db.portal.webservices.sms.holders.GetStatusResponseHolder)
    [clientgen] public void getStatus(com.db.portal.webservices.sms.GetStatus parameters, com.db.portal.webservices.sms.holders.GetStatusResponseHolder parameters)
    [clientgen] ^
    [clientgen] Note: C:\Documents and Settings\amitkumar.patel\Local Settings\Temp\ws_SmsService_client.jar699419996\com\db\dbdi\gtbportal\sms\client\SMSService.java uses or overrides a deprecated API.
    [clientgen] Note: Recompile with -deprecation for details.
    [clientgen] 4 errors
    *[*clientgen] java.io.IOException: Compiler failed executable.exec**
    [clientgen] at weblogic.utils.compiler.CompilerInvoker.compileMaybeExit(CompilerInvoker.java:470)
    [clientgen] at weblogic.utils.compiler.CompilerInvoker.compile(CompilerInvoker.java:328)
    [clientgen] at weblogic.utils.compiler.CompilerInvoker.compile(CompilerInvoker.java:336)
    [clientgen] at weblogic.webservice.tools.build.internal.CompilerHelper.compileFiles(CompilerHelper.java:80)
    [clientgen] at weblogic.webservice.tools.build.internal.ClientGenImpl.compileStubs(ClientGenImpl.java:627)
    [clientgen] at weblogic.webservice.tools.build.internal.ClientGenImpl.generateStub(ClientGenImpl.java:572)
    [clientgen] at weblogic.webservice.tools.build.internal.ClientGenImpl.doClientGenFromWsdl(ClientGenImpl.java:409)
    [clientgen] at weblogic.webservice.tools.build.internal.ClientGenImpl.run(ClientGenImpl.java:340)
    [clientgen] at weblogic.ant.taskdefs.webservices.clientgen.ClientGenTask.doClientGen(ClientGenTask.java:351)
    [clientgen] at weblogic.ant.taskdefs.webservices.clientgen.ClientGenTask.execute(ClientGenTask.java:208)
    [clientgen] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
    [clientgen] at org.apache.tools.ant.Task.perform(Task.java:364)
    [clientgen] at org.apache.tools.ant.Target.execute(Target.java:341)
    [clientgen] at org.apache.tools.ant.Target.performTasks(Target.java:369)
    [clientgen] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
    [clientgen] at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
    [clientgen] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:40)
    [clientgen] at org.eclipse.ant.internal.ui.antsupport.EclipseDefaultExecutor.executeTargets(EclipseDefaultExecutor.java:32)
    [clientgen] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
    [clientgen] at org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.run(InternalAntRunner.java:423)
    [clientgen] at org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.main(InternalAntRunner.java:137)
    BUILD FAILED
    D:\Java_Src_10.1.0\ant\build_weblogic8.xml:34: weblogic.webservice.tools.build.WSBuildException: Compiler failed executable.exec - with nested exception:
    [java.io.IOException: Compiler failed executable.exec]
    Total time: 1 minute 12 seconds

    Hi,
    Can u Please post the WSDL..here. I remember long back i resolved this kind of issue...when i was getting "*parameters is already defined in - - -*" while using ClientGen.
    Once i will get the WSDL may be i can recall it...
    If u have any problem in Posting the WSDL..in Forums .. then let me know I will send my E-Mail Address...
    As far as i remember ..it usually happens when we Run ClientGen task of WLS81 ON the WebService/WSDL generated by WebLogic 9.x or Above. Please let me know if this is the Case with you as well... . I remember there is a Patch for it...for WLS8 ClientGen task...I dont remember the Patch Number Exactly.
    Just For testing:
    Just Use WLS9.x ClientGen task On the Same WSDL
    <taskdef name="clientgen" classname="weblogic.wsee.tools.anttasks.ClientGenTask" />
    I am sure you will not see this issue... because the issue is there only with WLS8 Clientgen...
    Thanks
    Jay SenSharma
    http://jaysensharma.wordpress.com (WebLogic Wonders Are Here)
    Edited by: Jay SenSharma on Jan 8, 2010 4:32 PM
    Edited by: Jay SenSharma on Jan 8, 2010 4:34 PM

  • Error in generating adobe interactive form created from WSDL file

    Hi,
    I have created a form in SFP from a WSDL file.Copy paste the below program and when i run the program it gives me error message
    "_Adobe reader could not open ..Because it is either not supported file type or has been damaged (...)"_. I am not sure whether i am doing right.If this is not the right one, then how can i generate a interactive PDF from WSDL.
    DATA: ie_outputparams TYPE sfpoutputparams.
    DATA: i_name TYPE fpname,
    i_funcname TYPE funcname.
    DATA: fp_docparams TYPE sfpdocparams.
    DATA: fp_formoutput TYPE fpformoutput.
    DATA: data_tab TYPE solix_tab.
    ie_outputparams-getpdf = 'X'.
    ie_outputparams-nodialog = 'X'. " suppress printer dialog popup
    CALL FUNCTION 'FP_JOB_OPEN'
      CHANGING
        ie_outputparams = ie_outputparams.
    TRY.
       i_name = 'ZSPADOBE01'. "your form name
      i_name = 'Z....'. "your form name
        CALL FUNCTION 'FP_FUNCTION_MODULE_NAME'
          EXPORTING
            i_name     = i_name
          IMPORTING
            e_funcname = i_funcname.
      CATCH cx_fp_api_repository.
      CATCH cx_fp_api_usage.
      CATCH cx_fp_api_internal.
    ENDTRY.
    fp_docparams-langu = 'E'.
    fp_docparams-country = 'US'.
    fp_docparams-fillable = 'X'.
    CALL FUNCTION i_funcname
      EXPORTING
        /1bcdwb/docparams  = fp_docparams
      IMPORTING
        /1bcdwb/formoutput = fp_formoutput
      EXCEPTIONS
        usage_error        = 1
        system_error       = 2
        internal_error     = 3.
    CALL FUNCTION 'FP_JOB_CLOSE'
      EXCEPTIONS
        usage_error    = 1
        system_error   = 2
        internal_error = 3
        OTHERS         = 4.
    DATA: filename TYPE string,
    path TYPE string,
    fullpath TYPE string,
    default_extension TYPE string VALUE 'PDF'.
    cl_gui_frontend_services=>file_save_dialog(
    EXPORTING
    default_extension = default_extension
    CHANGING
    filename = filename
    path = path
    fullpath = fullpath ).
    CHECK fullpath IS NOT INITIAL.
    CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
      EXPORTING
        buffer     = fp_formoutput-pdf
      TABLES
        binary_tab = data_tab.
    cl_gui_frontend_services=>gui_download(
    EXPORTING
    filename = filename
    filetype = 'BIN'
    CHANGING
    data_tab = data_tab ).
    cl_gui_frontend_services=>execute(
    EXPORTING
    document = filename ).

    Hi Sanu,
    Hope this link help you.
    [CALLING WEB SERVICES IN INTERACTIVE ADOBE FORMS|http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/20280d13-7b93-2e10-51a0-ba05fd26355a]
    Regards,
    Shaira

Maybe you are looking for