As an update on this if I leave my jaxb appinfo binding
jaxb:typesafeEnumClass & jaxb:typesafeEnumMember in my wsdl & use the
bindings file to replace the XMLGregorianCalendar using wsimport then
everything works.. so this looks like a bug to me. CXF gives the error
pasted at the bottom

However wsimport does also seem to have a problem with having the
globalBindings & typesafeEnumMember in the external bindings.. 

<jaxws:bindings wsdlLocation="../Output/IdentityManagement_v1.wsdl"
        xmlns:jaxws="http://java.sun.com/xml/ns/jaxws";
        xmlns:xsd="http://www.w3.org/2001/XMLSchema";
        xmlns:jaxb="http://java.sun.com/xml/ns/jaxb";
        xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; version="2.0">
                        
        <jaxws:bindings 
node="wsdl:definitions/wsdl:types/xsd:[EMAIL 
PROTECTED]'http://www.test.com/ws/de']">
 
                <jaxb:globalBindings>

                        <jaxb:javaType name="java.sql.Date" xmlType="xsd:date"
                                parseMethod="valueOf"
                                printMethod="toString" />

                </jaxb:globalBindings> 
  
        </jaxws:bindings>       
</jaxws:bindings>

CXF error for inline jabx annotations & external bindings:
    [java] wsdl2java - Apache CXF (incubator) 2.0.5-incubator
     [java] WSDLToJava Error: Thrown by JAXB : compiler was unable to honor
this globalBindings customization. It is attached to a wrong place, or its
inconsistent with other bindings.
     [java] org.apache.cxf.tools.common.ToolException: Thrown by JAXB :
compiler was unable to honor this globalBindings customization. It is
attached to a wrong place, or its inconsistent with other bindings.
     [java]     at
org.apache.cxf.tools.wsdlto.databinding.jaxb.JAXBBindErrorListener.error(JAXBBindErrorListener.java:34)
     [java]     at
com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.error(SchemaCompilerImpl.java:245)
     [java]     at
com.sun.tools.xjc.util.ErrorReceiverFilter.error(ErrorReceiverFilter.java:61)
     [java]     at
com.sun.tools.xjc.util.ErrorReceiverFilter.error(ErrorReceiverFilter.java:61)
     [java]     at com.sun.tools.xjc.ErrorReceiver.error(ErrorReceiver.java:66)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.ErrorReporter.error(ErrorReporter.java:63)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.check(UnusedCustomizationChecker.java:105)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.check(UnusedCustomizationChecker.java:98)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.simpleType(UnusedCustomizationChecker.java:196)
     [java]     at
com.sun.xml.xsom.impl.SimpleTypeImpl.visit(SimpleTypeImpl.java:134)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.elementDecl(UnusedCustomizationChecker.java:189)
     [java]     at
com.sun.xml.xsom.impl.ElementDecl.visit(ElementDecl.java:202)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.particle(UnusedCustomizationChecker.java:202)
     [java]     at
com.sun.xml.xsom.impl.ParticleImpl.visit(ParticleImpl.java:88)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.modelGroup(UnusedCustomizationChecker.java:183)
     [java]     at
com.sun.xml.xsom.impl.ModelGroupImpl.visit(ModelGroupImpl.java:89)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.particle(UnusedCustomizationChecker.java:202)
     [java]     at
com.sun.xml.xsom.impl.ParticleImpl.visit(ParticleImpl.java:88)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.complexType(UnusedCustomizationChecker.java:143)
     [java]     at
com.sun.xml.xsom.impl.ComplexTypeImpl.visit(ComplexTypeImpl.java:237)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.run(UnusedCustomizationChecker.java:84)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.UnusedCustomizationChecker.run(UnusedCustomizationChecker.java:74)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.BGMBuilder._build(BGMBuilder.java:143)
     [java]     at
com.sun.tools.xjc.reader.xmlschema.BGMBuilder.build(BGMBuilder.java:77)
     [java]     at
com.sun.tools.xjc.ModelLoader.annotateXMLSchema(ModelLoader.java:388)
     [java]     at
com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:206)
     [java]     at
org.apache.cxf.tools.wsdlto.databinding.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:209)
     [java]     at
org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.generateTypes(WSDLToJavaContainer.java:531)
     [java]     at
org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:185)
     [java]     at
org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:231)
     [java]     at
org.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java:83)
     [java]     at
org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:102)
     [java]     at
org.apache.cxf.tools.wsdlto.WSDLToJava.main(WSDLToJava.java:171)
     [java] Caused by: com.sun.istack.SAXParseException2: compiler was
unable to honor this globalBindings customization. It is attached to a wrong
place, or its inconsistent with other bindings.
     [java]     ... 29 more
     [echo] ************************
-- 
View this message in context: 
http://www.nabble.com/jaxws-binding-issue-tp16823731p16823767.html
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to