<xs:element name="_SortFields" nillable="true" type="tns:_SortFields"/>
will conflict with
<xs:element name="SortFields" nillable="true" type="tns:SortFields"/>
giving the error:
Two declarations cause a collision in the ObjectFactory class.
line 300 of file:blah.xsd
(Related to above error) This is the other declaration.
line 385 of file:blah.xsd
because it is removing underscores from names by default.
A bindings file like this will fix it:
<jxb:bindings version="2.1" xmlns:jxb="http://java.sun.com/xml/ns/jaxb"
xmlns:xjc="http://java.sun.com/xml/ns/jaxb/xjc"
xmlns:jaxws="http://java.sun.com/xml/ns/jaxws"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<jxb:globalBindings underscoreBinding="asCharInWord">
<xjc:simple/>
<xjc:serializable />
</jxb:globalBindings>
</jxb:bindings>
title
fire chief's random developer tidbits
Showing posts with label web services. Show all posts
Showing posts with label web services. Show all posts
Wednesday, July 31, 2013
Tuesday, May 21, 2013
Logging soap contents with JAX-WS
Looking around the web, I found various system properties that were suggested for getting JAX-WS to dump the soap contents to system out. Different ones work for different situations. While I can't name all the situations, here are the properties all in one place. Set the appropriate one to "true". Sometimes the "brute force" solution of putting them all in, then trying one half or the other (binary search) might be the fastest way to figure it out without driving yourself crazy.
These can work when not using the internal/embedded JAX-WS in the JVM (for example running within Glassfish with a full Metro stack in place):
com.sun.xml.ws.transport.http.client.HttpTransportPipe.dump
com.sun.xml.ws.transport.http.HttpAdapter.dump
com.sun.xml.ws.transport.local.LocalTransportPipe.dump
These will work when using the Internal/embedded JAX-WS (for example running a single main class within Netbeans).
com.sun.xml.internal.ws.transport.http.client.HttpTransportPipe.dump
com.sun.xml.internal.ws.transport.http.HttpAdapter.dump
com.sun.xml.internal.ws.transport.local.LocalTransportPipe.dump
This was the one that actually worked in my situation, running a standalone JAX-WS client within Netbeans:
com.sun.xml.internal.ws.transport.http.client.HttpTransportPipe.dump
Subscribe to:
Posts (Atom)