wsimport

WSImport generates conflicting XMLTypes for multiple Dynamics CRM 4.0 WSDL's

江枫思渺然 提交于 2019-12-05 20:51:29
问题 I'm currently working with the Dynamics CRM 4.0 webservice. First thing I did, was generating the right classes with wsimport for Java/JAX-WS based on the WSDL of the webservice. While generating the classes I got some errors: [ERROR] A class/interface with the same name "com.microsoft.schemas.crm._2007.webservices.RetrieveResponse" is already in use. Use a class customization to resolve this conflict. line 979 of file://src/main/webapp/WEB-INF/classes/META-INF/wsdl/CrmServiceWsdl.wsdl [ERROR

wsimport not using complex input types

穿精又带淫゛_ 提交于 2019-12-05 19:39:33
问题 When I use wsimport to generate proxies for some services, the resulting method signature for each port does not seem to use the complex types specified in the WSDL; but yet I've noticed that with some other services it does. This has happened on multiple services, but the most recent example is Amazon's AWSEConsumerService (link to WSDL). When I generate the service proxy code using wsimport, I get method signatures such as the following for each port. @WebMethod(operationName = "ItemLookup"

What customization to apply for JAX-WS to unwrap return objects to lists?

点点圈 提交于 2019-12-05 14:43:16
I am trying to find if there is a way to customize e.g. CSID2ExtRefs operation for ChemSpider WebService that is passed a list of strings as one of the arguments and returns the list of objects: <!-- Request element: --> <s:element name="CSID2ExtRefs"> <s:complexType> <s:sequence> <s:element minOccurs="1" maxOccurs="1" name="CSID" type="s:int"/> <s:element minOccurs="0" maxOccurs="1" name="datasources" type="tns:ArrayOfString"/> <s:element minOccurs="0" maxOccurs="1" name="token" type="s:string"/> </s:sequence> </s:complexType> </s:element> <!-- Response element: --> <s:element name=

need to use custom classes instead of generated (by wsimport) in web-services

╄→гoц情女王★ 提交于 2019-12-05 12:42:02
Could you, please, help with the following issue? When generate WS client code (with wsimport ant task), all classes are generated automatically in the same package (e.g. helloservice.endpoint) as web service, e.g. if my web-service has method public Node getNode(); so class helloservice.endpoint.Node is generated. Nevertheless, I have my own helloservice.Node class that I want to use in web-service. I defined bind.xml file : <bindings version="2.0" xmlns="http://java.sun.com/xml/ns/jaxb" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" > <bindings node="wsdl:definitions/wsdl:portType[@name='Node

How to create folder for generated sources in Maven?

僤鯓⒐⒋嵵緔 提交于 2019-12-05 12:05:16
I have to generate sources using wsimport and i assume that it should go to /target/generated-sources/wsimport rather than /src/main/java. The problem is that wsimport needs target folder created before execution and it fails. Can I create that dir first using any maven plugin. I can do it using ant but i prefer to keep it in POM. I have to generate sources using wsimport and i assume that it should go to /target/generated-sources/wsimport rather than /src/main/java. This is a correct assumption. The problem is that wsimport needs target folder created before execution and it fails. Can I

How do I tell wsimport to use a proxy exception url

夙愿已清 提交于 2019-12-05 01:34:38
问题 I need to connect to an internal intranet web service. My company uses a proxy server to access the internet but intranet sites do not go through the proxy. I can navigate to the WSDL in IE and Firefox but I have to add the address to the proxy exception list in both browsers. When I use wsimport I cannot get the WSDL because of the proxy server. Adding in or leaving out the -httpproxy arg gives me an error "Unable to tunnel through proxy" so I'm guessing this is not the way I need to do it.

Applying external JAXB binding file to schema elements imported from WSDL

萝らか妹 提交于 2019-12-05 00:46:16
The XPath expression in my external binding files can't target the elements in my XML schemas which are imported into my WSDL. Everything runs if I do inline binding customization but I really wanted to have external binding files that way I never accidentally overwrite(refresh) the files containing my customizations. The start of my binding file: <jaxb:bindings xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:jaxws="http://java.sun.com/xml/ns/jaxws" version=

how to get maven-jaxws-plugin to generate @XmlElementWrapper on classes generated from xsd?

三世轮回 提交于 2019-12-04 23:58:39
问题 I am using maven-jaxws-plugin to generate java classes from my wsdl, schema. It is not generating the @XmlElementWrapper annotation in the generated classes. From this post I understand I nedd to use the jaxb-xew-plugin but am unable to get it working with the maven-jaxws-plugin. Any help would be appreciated. Here is the config I tried <plugin> <groupId>org.jvnet.jax-ws-commons</groupId> <artifactId>jaxws-maven-plugin</artifactId> <version>2.2</version> <executions> <execution> <goals> <goal

Why does wsimport have trouble with server object having @XmlRootElement annotation?

眉间皱痕 提交于 2019-12-04 18:36:18
I was completing work on a web service using JAX-WS on the server side. In many of the domain objects I used @XmlRootElement to help facilitate the unmarshaling of XML files into the service using JAXB. All went well and the output was what I expected to see using SoapUI. However, when I used wsimport to create the client (as a convenience DAO for other developers), I started encountering NullPointerExceptions in my client integration-test class. The call to the webservice worked correctly, and a response was received by the client, but my more-complex objects were null. Simple attributes,

XSD and WSDL in different directories

蓝咒 提交于 2019-12-04 12:26:10
问题 At my work used jaxws-maven-plugin for code generation. I have two projects are "common" and'' client ". Structure roughly as follows: app/ common/ resource/ some.xsd client/ resource/ some.wsdl How can I generate classes from wsdl in the project "client", using the xsd from the project "common"? pom.xml: <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>jaxws-maven-plugin</artifactId> <executions> <execution> <goals> <goal>wsimport</goal> </goals> <configuration> <verbose>true<