Re: WSDLToJava Error while upgrading Apache CXF

2020-11-26 Thread ragul rangarajan
Hi All,

Can anyone please help me with the problem?
Is there any information needed?

*Thanks and Regards*

*Ragul R*


On Thu, Nov 19, 2020 at 7:36 PM ragul rangarajan 
wrote:

> Hi All,
>
> 
>
> I am upgrading Apache CXF from 3.2.14 to 3.3.8 where I got stuck with the
> below exception while building wdsl client.
>
> [echo] TOTAL_MIB_ISAM_3.1.0.7.txt
>  [java] Nov 19, 2020 4:26:42 PM 
> org.apache.velocity.runtime.log.JdkLogChute log
>  [java] SEVERE: ResourceManager : unable to find resource 
> 'org/apache/cxf/tools/wsdlto/frontend/jaxws/template/fault.vm' in any 
> resource loader.
>  [java]
>  [java] WSDLToJava Error: Could not find Velocity template file: 
> org/apache/cxf/tools/wsdlto/frontend/jaxws/template/fault.vm
>  [java]
>  [java] org.apache.cxf.tools.common.ToolException: Could not find 
> Velocity template file: 
> org/apache/cxf/tools/wsdlto/frontend/jaxws/template/fault.vm
>  [java] at 
> org.apache.cxf.tools.common.VelocityGenerator.doWrite(VelocityGenerator.java:101)
>  [java] at 
> org.apache.cxf.tools.wsdlto.core.AbstractGenerator.doWrite(AbstractGenerator.java:54)
>  [java] at 
> org.apache.cxf.tools.wsdlto.frontend.jaxws.generators.FaultGenerator.generate(FaultGenerator.java:133)
>  [java] at 
> org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.processWsdl(WSDLToJavaContainer.java:288)
>  [java] at 
> org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:156)
>  [java] at 
> org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:404)
>  [java] at 
> org.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java:105)
>  [java] at 
> org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:113)
>  [java] at 
> org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:86)
>  [java] at 
> org.apache.cxf.tools.wsdlto.WSDLToJava.main(WSDLToJava.java:185)
>  [java] Caused by: 
> org.apache.velocity.exception.ResourceNotFoundException: Unable to find 
> resource 'org/apache/cxf/tools/wsdlto/frontend/jaxws/template/fault.vm'
>  [java] at 
> org.apache.velocity.runtime.resource.ResourceManagerImpl.loadResource(ResourceManagerImpl.java:474)
>  [java] at 
> org.apache.velocity.runtime.resource.ResourceManagerImpl.getResource(ResourceManagerImpl.java:352)
>  [java] at 
> org.apache.velocity.runtime.RuntimeInstance.getTemplate(RuntimeInstance.java:1533)
>  [java] at 
> org.apache.velocity.runtime.RuntimeInstance.getTemplate(RuntimeInstance.java:1514)
>  [java] at 
> org.apache.velocity.runtime.RuntimeSingleton.getTemplate(RuntimeSingleton.java:299)
>  [java] at 
> org.apache.velocity.app.Velocity.getTemplate(Velocity.java:358)
>  [java] at 
> org.apache.cxf.tools.common.VelocityGenerator.doWrite(VelocityGenerator.java:98)
>  [java] ... 9 more
> [INFO] 
> 
>
>
> Using the below task to generate WDSL client using WSDLToJava and
> specified all cxf related jars in its cxf.classpath. But still it couldn't
> find the resource in
> 'org/apache/cxf/tools/wsdlto/frontend/jaxws/template/fault.vm'
>
> *cxf.xml*
>
>failonerror="true">
> value="-Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl"/>
>
>
>
>
>
>   
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>  file="${org.apache.cxf:cxf-tools-wsdlto-databinding-jaxb:jar}"/>
>  file="${org.apache.cxf:cxf-tools-wsdlto-frontend-jaxws:jar}"/>
> 
>
> Can you please help me with the above issue?
>
> - I Have added Frontend-jaxws jar where the fault.vm files reside But
> still, it fails.
>
>   Do I need any other dependency to be added?
>
>
> *Thanks and Regards*
>
> *Ragul R*
>


Re: WSDLToJava Error: ...is already defined at...

2011-12-08 Thread Paul Baker
I am receiving the same type of error when generating the client stubs.  No
errors are generated when generating the service stubs.  The problem appears
to be associated with duplicate xsd includes AND the wsdl location.

Client errors generated (only when the wsdl includes a xsd that is nested in
another xsd AND when the wsdl is referenced using an URL). 

Errors:

[INFO] --- cxf-codegen-plugin:2.5.0:wsdl2java (generate-sources) @
myserviceclient ---
[INFO]

[INFO] BUILD FAILURE
[INFO]

[INFO] Total time: 7.810s
[INFO] Finished at: Thu Dec 08 05:11:20 EST 2011
[INFO] Final Memory: 39M/700M
[INFO]

[ERROR] Failed to execute goal
org.apache.cxf:cxf-codegen-plugin:2.5.0:wsdl2java (generate-sources) on
project ahm565: Thrown by JAXB:
[ERROR] Thrown by JAXB:
[ERROR] Thrown by JAXB: 'applicationException' is already defined
[ERROR] 
[ERROR] Thrown by JAXB: (related to above error) the first definition
appears here
[ERROR] 
[ERROR] Thrown by JAXB: 'concurrentUpdateException' is already defined
...

The service stubs are generated from a wsdl stored with the project.
The client stubs are generated from a deployed wsdl.

I am using maven for both the service and client generation

plugin
  groupIdorg.apache.cxf/groupId
   artifactIdcxf-codegen-plugin/artifactId
   version2.5.0/version
  executions
execution
  idgenerate-sources/id
  phasegenerate-sources/phase
  configuration
sourceRoot${project.basedir}/src/main/java/sourceRoot
  wsdlOptions
wsdlOption
   
wsdl${project.basedir}/WebContent/WEB-INF/wsdl/myservicer/MyService.wsdl/wsdl
/wsdlOption
/wsdlOptions
  /configuration
  goals
 goalwsdl2java/goal
   /goals
/execution
 /executions

 dependencies
 /dependencies
 inheritedtrue/inherited
/plugin


In the client maven pom everything is the same except the location of the
wsdl:
wsdlhttp://localhost:8080/MyService?wsdl/wsdl

The wsdl includes two xsds:

wsdl:types
  xsd:schema xmlns:xsd=http://www.w3.org/2001/XMLSchema;
 xsd:import
namespace=http://www.widget.com/service/myservice/jaxb/to/;
schemaLocation=../../xsd/myservice/MyService.xsd /
 xsd:import namespace=http://www.widget.com/service/common/jaxb/to/;
schemaLocation=../../xsd/common/Common.xsd /
   /xsd:schema
/wsdl:types

The MyService.xsd also includes Common.xsd.

If I remove Common.xsd from the wsdl file then all code is generated with no
errors... But, when the wsdl is displayed in Eclipse with the wsdl editor
then errors are displayed.






--
View this message in context: 
http://cxf.547215.n5.nabble.com/WSDLToJava-Error-is-already-defined-at-tp5010580p5058342.html
Sent from the cxf-user mailing list archive at Nabble.com.


Re: WSDLToJava Error: ...is already defined at...

2011-12-08 Thread Daniel Kulp

Any chance you could distill this down into a small testcase and attach it to 
a JIRA?

Thanks!
Dan


On Thursday, December 08, 2011 2:42:11 AM Paul Baker wrote:
 I am receiving the same type of error when generating the client stubs.  No
 errors are generated when generating the service stubs.  The problem appears
 to be associated with duplicate xsd includes AND the wsdl location.
 
 Client errors generated (only when the wsdl includes a xsd that is nested in
 another xsd AND when the wsdl is referenced using an URL).
 
 Errors:
 
 [INFO] --- cxf-codegen-plugin:2.5.0:wsdl2java (generate-sources) @
 myserviceclient ---
 [INFO]
 
 [INFO] BUILD FAILURE
 [INFO]
 
 [INFO] Total time: 7.810s
 [INFO] Finished at: Thu Dec 08 05:11:20 EST 2011
 [INFO] Final Memory: 39M/700M
 [INFO]
 
 [ERROR] Failed to execute goal
 org.apache.cxf:cxf-codegen-plugin:2.5.0:wsdl2java (generate-sources) on
 project ahm565: Thrown by JAXB:
 [ERROR] Thrown by JAXB:
 [ERROR] Thrown by JAXB: 'applicationException' is already defined
 [ERROR]
 [ERROR] Thrown by JAXB: (related to above error) the first definition
 appears here
 [ERROR]
 [ERROR] Thrown by JAXB: 'concurrentUpdateException' is already defined
 ...
 
 The service stubs are generated from a wsdl stored with the project.
 The client stubs are generated from a deployed wsdl.
 
 I am using maven for both the service and client generation
 
 plugin
   groupIdorg.apache.cxf/groupId
artifactIdcxf-codegen-plugin/artifactId
version2.5.0/version
   executions
 execution
   idgenerate-sources/id
   phasegenerate-sources/phase
   configuration
 sourceRoot${project.basedir}/src/main/java/sourceRoot
   wsdlOptions
 wsdlOption
 
 wsdl${project.basedir}/WebContent/WEB-INF/wsdl/myservicer/MyService.wsdl/
 wsdl /wsdlOption
   /wsdlOptions
   /configuration
   goals
  goalwsdl2java/goal
/goals
 /execution
  /executions
 
  dependencies
  /dependencies
  inheritedtrue/inherited
 /plugin
 
 
 In the client maven pom everything is the same except the location of the
 wsdl:
 wsdlhttp://localhost:8080/MyService?wsdl/wsdl
 
 The wsdl includes two xsds:
 
 wsdl:types
   xsd:schema xmlns:xsd=http://www.w3.org/2001/XMLSchema;
  xsd:import
 namespace=http://www.widget.com/service/myservice/jaxb/to/;
 schemaLocation=../../xsd/myservice/MyService.xsd /
  xsd:import namespace=http://www.widget.com/service/common/jaxb/to/;
 schemaLocation=../../xsd/common/Common.xsd /
/xsd:schema
 /wsdl:types
 
 The MyService.xsd also includes Common.xsd.
 
 If I remove Common.xsd from the wsdl file then all code is generated with no
 errors... But, when the wsdl is displayed in Eclipse with the wsdl editor
 then errors are displayed.
 
 
 
 
 
 
 --
 View this message in context:
 http://cxf.547215.n5.nabble.com/WSDLToJava-Error-is-already-defined-at-tp50
 10580p5058342.html Sent from the cxf-user mailing list archive at
 Nabble.com.
-- 
Daniel Kulp
dk...@apache.org - http://dankulp.com/blog
Talend Community Coder - http://coders.talend.com


Re: WSDLToJava Error: ...is already defined at...

2011-11-21 Thread Daniel Kulp
On Monday, November 21, 2011 5:59:11 AM blicket wrote:
 I'm using the wsdl2java tool to generate all.  The problem is that there is
 no where else where this type is already defined.   If I comment out the
 definition, then it complains it's not defined.  I'm using a common schema
 style for the most part.  THank you. 

We'd likely need to see the WSDL.   

Also, if you aren't using CXF 2.5.0, definitely try with it.  As part of 
CXF-3887 which is fixed in 2.5.0, I updated the XJC calls to allow JAXB to 
report multiple errors which MAY provide more information about this.  In some 
cases which JAXB reports a duplicate, it would send an error like above in one 
error message, but then immediately follow it with a second error message 
about where the duplicate is located.   That second error message was not 
picked up, but in this case could be valuable information.

Dan




 
 --
 View this message in context:
 http://cxf.547215.n5.nabble.com/WSDLToJava-Error-is-already-defined-at-tp50
 10580p5010580.html Sent from the cxf-user mailing list archive at
 Nabble.com.
-- 
Daniel Kulp
dk...@apache.org - http://dankulp.com/blog
Talend Community Coder - http://coders.talend.com


Re: WSDLToJava Error: ...is already defined at...

2011-11-21 Thread blicket
I just tried using 2.5.0, no luck.  Just the same (single) message:

WSDLToJava Error: Thrown by JAXB: 'TestAcknowledgements' is already defined
at line 43 column 14 of schema file:

The following is with the -verbose option:

at
rg.apache.cxf.tools.wsdlto.databinding.jaxb.JAXBBindErrorListener.error(JAXBBindErrorListener.java:35)
at
com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.error(SchemaCompilerImpl.java:286)
at
com.sun.tools.xjc.util.ErrorReceiverFilter.error(ErrorReceiverFilter.java:77)
at
com.sun.xml.xsom.impl.parser.ParserContext$2.error(ParserContext.java:202)
at
com.sun.xml.xsom.impl.parser.ParserContext$1.reportError(ParserContext.java:180)
at
com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.reportError(NGCCRuntimeEx.java:170)
at
com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.reportError(NGCCRuntimeEx.java:173)
at
com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.checkDoubleDefError(NGCCRuntimeEx.java:145)
at com.sun.xml.xsom.impl.parser.state.Schema.action5(Schema.java:88)
at
com.sun.xml.xsom.impl.parser.state.Schema.onChildCompleted(Schema.java:1248)
at
com.sun.xml.xsom.impl.parser.state.NGCCHandler.revertToParentFromText(NGCCHandler.java:144)
at
com.sun.xml.xsom.impl.parser.state.complexType.text(complexType.java:1600)
at
com.sun.xml.xsom.impl.parser.state.NGCCRuntime.processPendingText(NGCCRuntime.java:197)
at
com.sun.xml.xsom.impl.parser.state.NGCCRuntime.endElement(NGCCRuntime.java:273)
at
org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
at
com.sun.tools.xjc.util.SubtreeCutter.endElement(SubtreeCutter.java:108)
at
org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
at
org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
at
com.sun.tools.xjc.reader.xmlschema.parser.CustomizationContextChecker.endElement(CustomizationContextChecker.java:194)
at
org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
at
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:601)
at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1782)
at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2939)
at
com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:648)
at
com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:140)
at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:511)
at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:808)
at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)
at
com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:119)
at
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1205)
at
com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:522)
at org.xml.sax.helpers.XMLFilterImpl.parse(XMLFilterImpl.java:333)
at com.sun.xml.xsom.parser.JAXPParser.parse(JAXPParser.java:115)
at
com.sun.tools.xjc.reader.internalizer.DOMForestParser.parse(DOMForestParser.java:95)
at
com.sun.tools.xjc.ModelLoader$XMLSchemaParser.parse(ModelLoader.java:262)
at
com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.parseEntity(NGCCRuntimeEx.java:337)
at
com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.includeSchema(NGCCRuntimeEx.java:234)
at
com.sun.xml.xsom.impl.parser.state.includeDecl.action0(includeDecl.java:43)
at
com.sun.xml.xsom.impl.parser.state.includeDecl.leaveElement(includeDecl.java:132)
at
com.sun.xml.xsom.impl.parser.state.NGCCRuntime.endElement(NGCCRuntime.java:275)
at
org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
at
com.sun.tools.xjc.util.SubtreeCutter.endElement(SubtreeCutter.java:108)
at
org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
at
org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
at
com.sun.tools.xjc.reader.xmlschema.parser.CustomizationContextChecker.endElement(CustomizationContextChecker.java:194)
at
org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
at
com.sun.tools.xjc.reader.internalizer.DOMForestScanner$LocationResolver.endElement(DOMForestScanner.java:135)
at
com.sun.xml.bind.unmarshaller.DOMScanner.visit(DOMScanner.java:250)
at
com.sun.xml.bind.unmarshaller.DOMScanner.visit(DOMScanner.java:276)
at

Re: WSDLToJava Error: ...is already defined at...

2011-11-21 Thread blicket
CXF-3927 was just created.  Please take a look.  Thanks.

--
View this message in context: 
http://cxf.547215.n5.nabble.com/WSDLToJava-Error-is-already-defined-at-tp5010580p5011589.html
Sent from the cxf-user mailing list archive at Nabble.com.


Re: WSDLToJava Error: ...is already defined at...

2011-11-21 Thread blicket
I'll try to upload an example by tomorrow.  I have to scrub it first.

--
View this message in context: 
http://cxf.547215.n5.nabble.com/WSDLToJava-Error-is-already-defined-at-tp5010580p5011619.html
Sent from the cxf-user mailing list archive at Nabble.com.


Re: WSDLToJava Error

2011-05-16 Thread Freeman Fang

Hi,

My comment inline
On 2011-5-16, at 下午5:22, David wrote:


Hi,

I am trying to use ant with cxf (2.3.3) to generate stub from wsdl.

Here is part of my ant script:

   path id=cxf.classpath
pathelement location=${target.classes.dir}/
fileset dir=${env.CXF_HOME}/lib
include name=*.jar/
/fileset
/path

target name=generateCXFClient depends=clean
		java classname=org.apache.cxf.tools.wsdlto.WSDLToJava  
fork=true

arg value=-d/
arg value=${target.gen.dir}/
arg value=-compile/
arg value=-client/
arg value=-exsh/
arg value=false/
arg value=-dns/
arg value=true/
arg value=-dex/
arg value=true/
arg value=-verbose/



arg value=${wsdl.file.remote}/
classpath
path refid=cxf.classpath/
/classpath
/java
/target

And here is the error:

[java] wsdl2java - Apache CXF 2.3.3
[java] WSDLToJava Error:  
java.lang.reflect.UndeclaredThrowableException

[java] org.apache.cxf.tools.common.ToolException:
java.lang.reflect.UndeclaredThrowableException
[java]  at
org 
.apache 
.cxf 
.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java: 
291)

[java]  at
org 
.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java: 
103)

[java]  at
org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:113)
[java]  at
org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:86)
[java]  at
org.apache.cxf.tools.wsdlto.WSDLToJava.main(WSDLToJava.java:184)
[java] Caused by: java.lang.reflect.UndeclaredThrowableException
[java]  at $Proxy40.required(Unknown Source)
[java]  at
com 
.sun 
.tools 
.xjc 
.generator 
.bean.field.AbstractField.annotateReference(AbstractField.java:187)

[java]  at
com 
.sun 
.tools 
.xjc.generator.bean.field.AbstractField.annotate(AbstractField.java: 
156)

[java]  at
com 
.sun 
.tools 
.xjc 
.generator 
.bean 
.field.AbstractFieldWithVar.createField(AbstractFieldWithVar.java:75)

[java]  at
com 
.sun 
.tools.xjc.generator.bean.field.SingleField.init(SingleField.java: 
89)

[java]  at
com 
.sun 
.tools.xjc.generator.bean.field.SingleField.init(SingleField.java: 
76)

[java]  at
sun.reflect.GeneratedConstructorAccessor16.newInstance(Unknown Source)
[java]  at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown  
Source)
[java] 	at java.lang.reflect.Constructor.newInstance(Unknown  
Source)

[java]  at
com 
.sun 
.tools 
.xjc 
.generator 
.bean.field.GenericFieldRenderer.generate(GenericFieldRenderer.java: 
64)

[java]  at
com 
.sun 
.tools 
.xjc 
.generator 
.bean.field.DefaultFieldRenderer.generate(DefaultFieldRenderer.java: 
79)

[java]  at
com 
.sun 
.tools 
.xjc 
.generator.bean.BeanGenerator.generateFieldDecl(BeanGenerator.java: 
759)

[java]  at
com 
.sun 
.tools 
.xjc 
.generator.bean.BeanGenerator.generateClassBody(BeanGenerator.java: 
540)

[java]  at
com 
.sun 
.tools.xjc.generator.bean.BeanGenerator.init(BeanGenerator.java:243)

[java]  at
com 
.sun 
.tools.xjc.generator.bean.BeanGenerator.generate(BeanGenerator.java: 
161)
[java] 	at com.sun.tools.xjc.model.Model.generateCode(Model.java: 
286)

[java]  at
com 
.sun 
.tools 
.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:252)

[java]  at
com 
.sun 
.tools 
.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:85)

[java]  at
org 
.apache 
.cxf 
.tools 
.wsdlto 
.databinding.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:392)

[java]  at
org 
.apache 
.cxf 
.tools 
.wsdlto.WSDLToJavaContainer.generateTypes(WSDLToJavaContainer.java: 
585)

[java]  at
org 
.apache 
.cxf 
.tools 
.wsdlto.WSDLToJavaContainer.processWsdl(WSDLToJavaContainer.java:240)

[java]  at
org 
.apache 
.cxf 
.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java: 
138)

[java]  at
org 
.apache 
.cxf 
.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java: 
283)

[java]  ... 4 more
[java] Caused by: java.lang.NoSuchMethodException:
javax.xml.bind.annotation.XmlElementRef.required()
[java]  at java.lang.Class.getDeclaredMethod(Unknown Source)
[java]  at
com 
.sun 
.codemodel.TypedAnnotationWriter.invoke(TypedAnnotationWriter.java: 
108)

[java]  ... 27 more



java.xml.bind.annotation.XmlElementRef.required() is from jaxb2.2 api,  
however java6 build-in jaxws 2.1 api which cause 

Re: WSDLToJava Error

2011-05-16 Thread David
Thank you very much.
It works now.

--
View this message in context: 
http://cxf.547215.n5.nabble.com/WSDLToJava-Error-tp4399830p4399937.html
Sent from the cxf-user mailing list archive at Nabble.com.


Re: WSDLToJava Error

2009-10-27 Thread Daniel Kulp

It's possible that the modified schema is causing issues.   What's the stack 
trace if you run wsdl2java with -v?

Also, you can try adding: -noAddressBinding to wsdl2java to turn off the 
internal mapping of the ws-addressing schema into javax.xml.ws.wsaddressing 
types.   It would actually generate types for stuff in the schema which may or 
may not be appropriate for what you need to accomplish, but worth a shot.

That said, using a catalog or something to map that schemaLocation to a local 
xsd is probably the best option.

Dan



On Tue October 27 2009 9:19:43 am Nate Woody wrote:
 I maintain a CXF-interface to Microsofts HPC2008 webservice (meaning the
 WSDL exists in the wild), which we recently upgraded and I'm unable to
 build stubs off of the WSDL anymore.  I've tried wsdltojava from 2.3 and
 2.4, but I get the same error.   It's a WS-Addressing error of some
 sort, but I'm not sure if it's a CXF bug.  The WSDL provides an import
 for WS-A:
 
   xsd:import
 
 schemaLocation=http://hostname/WSDL?xsd=xsd5;
 
 namespace=http://www.w3.org/2005/08/addressing;
 /
 
 
 
 Which refers to a partial schema I've pasted at the bottom of the email.
 If I change that import to point to a local ws-addr.xsd taken from the
 W3 site then the service builds and works OK.  The provided schema is
 missing these entries, which I suspect is what breaks things.
 
 
 
   xs:element name=ReplyTo type=tns:EndpointReferenceType/
 
   xs:element name=From type=tns:EndpointReferenceType/
 
   xs:element name=FaultTo type=tns:EndpointReferenceType/
 
   xs:element name=To type=tns:AttributedURIType/
 
   xs:element name=Action type=tns:AttributedURIType/
 
 
 
 I can provide a test case and put in a JIRA ticket if the dev's think
 this is a CXF bug.
 
 
 
 Thanks,
 
 Nate
 
 
 
 
 
 Partial WS-A schema:
 
 
 
 xs:schema elementFormDefault=qualified
 targetNamespace=http://www.w3.org/2005/08/addressing;
 
 xs:complexType name=EndpointReferenceType
 
 xs:sequence
 
 xs:element minOccurs=0 maxOccurs=1 name=Address
 type=tns:AttributedURIType/
 
 xs:element minOccurs=0 maxOccurs=1 name=ReferenceParameters
 type=tns:ReferenceParametersType/
 
 xs:element minOccurs=0 maxOccurs=1 name=Metadata
 type=tns:MetadataType/
 
 xs:any minOccurs=0 maxOccurs=unbounded namespace=##other/
 
 /xs:sequence
 
 xs:anyAttribute/
 
 /xs:complexType
 
 xs:complexType name=AttributedURIType
 
 xs:simpleContent
 
 xs:extension base=xs:anyURI
 
 xs:anyAttribute/
 
 /xs:extension
 
 /xs:simpleContent
 
 /xs:complexType
 
 xs:complexType name=ReferenceParametersType
 
 xs:sequence
 
 xs:any minOccurs=0 maxOccurs=unbounded/
 
 /xs:sequence
 
 xs:anyAttribute/
 
 /xs:complexType
 
 xs:complexType name=MetadataType
 
 xs:sequence
 
 xs:any minOccurs=0 maxOccurs=unbounded/
 
 /xs:sequence
 
 xs:anyAttribute/
 
 /xs:complexType
 
 /xs:schema
 

-- 
Daniel Kulp
dk...@apache.org
http://www.dankulp.com/blog


RE: WSDLToJava Error

2009-10-27 Thread Nate Woody

Sorry, thought I'd included the stack trace initially.  The
-noAddressBinding allows wsdl2java to finish successfully, but looks
like it breaks things.  At the very least the existing code doesn't work
and like you say I've got a workaround with replacing the Addressing
schema.

Thanks,
Nate




 [java] Loading FrontEnd jaxws ...
 [java] Loading DataBinding jaxb ...
 [java] wsdl2java -client -d src -verbose http://hostname/WSDL?wsdl
 [java] wsdl2java - Apache CXF 2.2.4
 [java] WSDLToJava Error: Thrown by JAXB : SCD wsa:From didnt
match any schema component at line 32 column 28 of schema
jar:file:/C:/Documents%20and%20Settings/nate/Desktop/apache-cxf-2.2.4/li
b/cxf-2.2.4.jar!/org/apache/cxf/tools/wsdlto/databinding/jaxb/W3CEPRJaxb
Binding.xml
 [java] org.apache.cxf.tools.common.ToolException: Thrown by JAXB :
SCD wsa:From didnt match any schema component at line 32 column 28 of
schema
jar:file:/C:/Documents%20and%20Settings/nate/Desktop/apache-cxf-2.2.4/li
b/cxf-2.2.4.jar!/org/apache/cxf/tools/wsdlto/databinding/jaxb/W3CEPRJaxb
Binding.xml
 [java] at
org.apache.cxf.tools.wsdlto.databinding.jaxb.JAXBBindErrorListener.error
(JAXBBindErrorListener.java:35)
 [java] at
com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.error(SchemaCompilerIm
pl.java:286)
 [java] at
com.sun.tools.xjc.util.ErrorReceiverFilter.error(ErrorReceiverFilter.jav
a:77)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.reportError(SCD
BasedBindingSet.java:255)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.reportError(SCD
BasedBindingSet.java:246)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.access$100(SCDB
asedBindingSet.java:74)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.apply(SC
DBasedBindingSet.java:154)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.applyAll
(SCDBasedBindingSet.java:138)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.apply(SC
DBasedBindingSet.java:159)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.applyAll
(SCDBasedBindingSet.java:138)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.access$7
00(SCDBasedBindingSet.java:82)
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.apply(SCDBasedB
indingSet.java:237)
 [java] at
com.sun.tools.xjc.ModelLoader.createXSOM(ModelLoader.java:522)
 [java] at
com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImp
l.java:236)
 [java] at
com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImp
l.java:85)
 [java] at
org.apache.cxf.tools.wsdlto.databinding.jaxb.JAXBDataBinding.initialize(
JAXBDataBinding.java:328)
 [java] at
org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.generateTypes(WSDLToJava
Container.java:568)
 [java] at
org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.processWsdl(WSDLToJavaCo
ntainer.java:219)
 [java] at
org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContai
ner.java:127)
 [java] at
org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContai
ner.java:263)
 [java] at
org.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java:
103)
 [java] at
org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:113)
 [java] at
org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:86)
 [java] at
org.apache.cxf.tools.wsdlto.WSDLToJava.main(WSDLToJava.java:184)
 [java] Caused by: com.sun.istack.SAXParseException2: SCD wsa:From
didnt match any schema component
 [java] at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.reportError(SCD
BasedBindingSet.java:252)
 [java] ... 20 more


-Original Message-
From: Daniel Kulp [mailto:dk...@apache.org] 
Sent: Tuesday, October 27, 2009 2:27 PM
To: users@cxf.apache.org
Cc: Nate Woody
Subject: Re: WSDLToJava Error


It's possible that the modified schema is causing issues.   What's the
stack 
trace if you run wsdl2java with -v?

Also, you can try adding: -noAddressBinding to wsdl2java to turn off the

internal mapping of the ws-addressing schema into
javax.xml.ws.wsaddressing 
types.   It would actually generate types for stuff in the schema which
may or 
may not be appropriate for what you need to accomplish, but worth a
shot.

That said, using a catalog or something to map that schemaLocation to a
local 
xsd is probably the best option.

Dan



On Tue October 27 2009 9:19:43 am Nate Woody wrote:
 I maintain a CXF-interface to Microsofts HPC2008 webservice (meaning
the
 WSDL exists in the wild), which we recently upgraded and I'm unable to
 build stubs off of the WSDL anymore.  I've tried wsdltojava from 2.3
and
 2.4, but I get the same error.   It's a WS-Addressing error of some
 sort, but I'm

Re: WSDLToJava Error

2009-10-27 Thread Daniel Kulp
On Tue October 27 2009 3:08:51 pm Nate Woody wrote:
 Sorry, thought I'd included the stack trace initially.  The
 -noAddressBinding allows wsdl2java to finish successfully, but looks
 like it breaks things.  At the very least the existing code doesn't work
 and like you say I've got a workaround with replacing the Addressing
 schema.

Ah.  Yes  Without -noAddressBinding, we use W3CEPRJaxbBinding.xml which is 
a JAXB binding file to map all the ws-addressing types into the proper 
javax.xml.ws.wsaddressing types.   Since their schema is missing some of those 
types, that mapping breaks.   Yep.  Looks like the workaround is the best 
option.

Dan


 
 Thanks,
 Nate
 
 
 
 
  [java] Loading FrontEnd jaxws ...
  [java] Loading DataBinding jaxb ...
  [java] wsdl2java -client -d src -verbose http://hostname/WSDL?wsdl
  [java] wsdl2java - Apache CXF 2.2.4
  [java] WSDLToJava Error: Thrown by JAXB : SCD wsa:From didnt
 match any schema component at line 32 column 28 of schema
 jar:file:/C:/Documents%20and%20Settings/nate/Desktop/apache-cxf-2.2.4/li
 b/cxf-2.2.4.jar!/org/apache/cxf/tools/wsdlto/databinding/jaxb/W3CEPRJaxb
 Binding.xml
  [java] org.apache.cxf.tools.common.ToolException: Thrown by JAXB :
 SCD wsa:From didnt match any schema component at line 32 column 28 of
 schema
 jar:file:/C:/Documents%20and%20Settings/nate/Desktop/apache-cxf-2.2.4/li
 b/cxf-2.2.4.jar!/org/apache/cxf/tools/wsdlto/databinding/jaxb/W3CEPRJaxb
 Binding.xml
  [java]   at
 org.apache.cxf.tools.wsdlto.databinding.jaxb.JAXBBindErrorListener.error
 (JAXBBindErrorListener.java:35)
  [java]   at
 com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.error(SchemaCompilerIm
 pl.java:286)
  [java]   at
 com.sun.tools.xjc.util.ErrorReceiverFilter.error(ErrorReceiverFilter.jav
 a:77)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.reportError(SCD
 BasedBindingSet.java:255)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.reportError(SCD
 BasedBindingSet.java:246)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.access$100(SCDB
 asedBindingSet.java:74)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.apply(SC
 DBasedBindingSet.java:154)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.applyAll
 (SCDBasedBindingSet.java:138)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.apply(SC
 DBasedBindingSet.java:159)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.applyAll
 (SCDBasedBindingSet.java:138)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet$Target.access$7
 00(SCDBasedBindingSet.java:82)
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.apply(SCDBasedB
 indingSet.java:237)
  [java]   at
 com.sun.tools.xjc.ModelLoader.createXSOM(ModelLoader.java:522)
  [java]   at
 com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImp
 l.java:236)
  [java]   at
 com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImp
 l.java:85)
  [java]   at
 org.apache.cxf.tools.wsdlto.databinding.jaxb.JAXBDataBinding.initialize(
 JAXBDataBinding.java:328)
  [java]   at
 org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.generateTypes(WSDLToJava
 Container.java:568)
  [java]   at
 org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.processWsdl(WSDLToJavaCo
 ntainer.java:219)
  [java]   at
 org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContai
 ner.java:127)
  [java]   at
 org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContai
 ner.java:263)
  [java]   at
 org.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java:
 103)
  [java]   at
 org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:113)
  [java]   at
 org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:86)
  [java]   at
 org.apache.cxf.tools.wsdlto.WSDLToJava.main(WSDLToJava.java:184)
  [java] Caused by: com.sun.istack.SAXParseException2: SCD wsa:From
 didnt match any schema component
  [java]   at
 com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.reportError(SCD
 BasedBindingSet.java:252)
  [java]   ... 20 more
 
 
 -Original Message-
 From: Daniel Kulp [mailto:dk...@apache.org]
 Sent: Tuesday, October 27, 2009 2:27 PM
 To: users@cxf.apache.org
 Cc: Nate Woody
 Subject: Re: WSDLToJava Error
 
 
 It's possible that the modified schema is causing issues.   What's the
 stack
 trace if you run wsdl2java with -v?
 
 Also, you can try adding: -noAddressBinding to wsdl2java to turn off the
 
 internal mapping of the ws-addressing schema into
 javax.xml.ws.wsaddressing
 types.   It would actually generate types for stuff in the schema which
 may or
 may not be appropriate for what you need to accomplish, but worth a
 shot.
 
 That said, using a catalog

RE: WSDLToJava Error | xmldsig-core-schema.xsd | Connection timed out

2008-06-05 Thread McClelland, Chris (IT)
Can you send your WSDL(s)?


From: Manolescu, Radu (IT)
Sent: 05 June 2008 16:15
To: cxf-ea; users@cxf.apache.org
Subject: WSDLToJava Error | xmldsig-core-schema.xsd | Connection timed out

I am trying to generate client code from a WSDL file, and I am getting the 
error below.
My WSDL references an XSD (authored by our counterpart) which references the 
public file oasis-200401-wss-wssecurity-secext-1.0.xsd, which references the 
public file xmldsig-core-schema.xsd.
I tried to use Eclipse to validate the WSDL and XSD files, and when Eclipse 
complained that it could not read some XSD files, I downloaded them locally and 
changed the schemaLocation references accordingly.

The last errors, which I cannot seem to be able to remove, are:

 *   oasis-200401-wss-wssecurity-secext-1.0.xsd does not pass Eclipse 
validation. Eclipse complains about being unable to read 
xmldsig-core-schema.xsd, whether that file is referenced locally or from the 
Internet
 *   when using Ant to call wsdl2java to generate the client, I get the 
exception below. Which program is trying to connect, and where? Is Ant trying 
to download files from the Internet while parsing xmldsig-core-schema.xsd?. 
If so, how can I make it connect? Define a proxy somewhere? Download the 
dependencies locally?



wsdl2java:

[java] WSDLToJava Error : java.lang.RuntimeException: Fail to create wsdl 
definition from : file:/U:/NonVerConPrj/MyProj/src/ide-bin/etc/Nodal.wsdl

[java] Caused by : WSDLException (at 
/wsdl:definitions/wsdl:types/xs:schema/xsd:schema/xsd:schema): 
faultCode=PARSER_ERROR: Problem parsing 
'file:/U:/NonVerConPrj/MyProj/src/ide-bin/etc/xmldsig-core-schema.xsd'.: 
java.net.ConnectException: Connection timed out: connect



Public file references:

http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd,
 saved locally as 
oasis-200401-wss-wssecurity-secext-1.0.xsdhttp://www.docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd
 (attached)

http://www.w3.org/TR/xmldsig-core/xmldsig-core-schema.xsd, saved locally as 
xmldsig-core-schema.xsdhttp://www.w3.org/TR/xmldsig-core/xmldsig-core-schema.xsd
 (attached)

http://www.w3.org/2001/xml.xsd, saved locally as 
xml.xsdhttp://www.w3.org/2001/xml.xsd



Thanks,


Radu Manolescu
Morgan Stanley | Technology
2000 Westchester Ave, 1st Floor | Purchase, NY  10577
Phone: +1 914 225-5871
Mobile: +1 203 648-6964
[EMAIL PROTECTED]mailto:[EMAIL PROTECTED]


NOTICE: If received in error, please destroy and notify sender. Sender does not 
intend to waive confidentiality or privilege. Use of this email is prohibited 
when received in error.


RE: WSDLToJava Error | xmldsig-core-schema.xsd | Connection timed out

2008-06-05 Thread Manolescu, Radu (IT)
This was due to a firewall issue. By adding proxy information to the
wsdl2java command line, I was able to move on to more challenging error
messages:

java -DproxySet=true -DproxyHost=myProxy.myCompany.com
-DproxyPort=myPort org.apache.cxf.tools.wsdlto.WSDLToJava -d ..
FileName.wsdl

Now I am battling body part errors such as:

In a port, operations must have unique operation signaure on the wire
for successful dispatch.
In port {http://www.myCo.com/wsdl/2007-06/abcd/efgh}HttpEndPoint,
Operations
{http://www.myCo.com/wsdl/2007-06/abcd/efgh}Op1; and
{http://www.myCo.com/wsdl/2007-06/abcd/efgh}Op2;
have the same request body block
{http://www.myCo.com/schema/2007-06/abcd/ews/message}RequestMessage 

I assume that we need to contact the web service provider and ask them
to modify the WSDL to have unique signatures for each operation.

Thanks,


Radu Manolescu
Morgan Stanley | Technology
2000 Westchester Ave, 1st Floor | Purchase, NY  10577
Phone: +1 914 225-5871
Mobile: +1 203 648-6964
[EMAIL PROTECTED]

-Original Message-
From: Daniel Kulp [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 05, 2008 4:57 PM
To: users@cxf.apache.org
Cc: cxf-ea
Subject: Re: WSDLToJava Error | xmldsig-core-schema.xsd | Connection
timed out



If eclipse is having problems reading it, most likely we cannot  
either. I'm not exactly sure how you can get a connection timed  
out error with a file URL.   That seams a bit strange.   Maybe a  
permissions issue?   Is the file really readable?  (can you cat it?  
load it in notepad?)

Dan



On Jun 5, 2008, at 11:14 AM, Manolescu, Radu (IT) wrote:

 I am trying to generate client code from a WSDL file, and I am getting

 the error below.
 My WSDL references an XSD (authored by our counterpart) which 
 references the public file oasis-200401-wss-wssecurity- 
 secext-1.0.xsd, which references the public file xmldsig-core- 
 schema.xsd.
 I tried to use Eclipse to validate the WSDL and XSD files, and when 
 Eclipse complained that it could not read some XSD files, I downloaded

 them locally and changed the schemaLocation references accordingly.

 The last errors, which I cannot seem to be able to remove, are:
   * oasis-200401-wss-wssecurity-secext-1.0.xsd does not pass
Eclipse 
 validation. Eclipse complains about being unable to read 
 xmldsig-core-schema.xsd, whether that file is referenced locally or 
 from the Internet
   * when using Ant to call wsdl2java to generate the client, I get
the 
 exception below. Which program is trying to connect, and where?
 Is Ant trying to download files from the Internet while parsing 
 xmldsig-core-schema.xsd?. If so, how can I make it connect? Define a

 proxy somewhere? Download the dependencies locally?

 wsdl2java:

 [java] WSDLToJava Error : java.lang.RuntimeException: Fail to create 
 wsdl definition from : file:/U:/NonVerConPrj/MyProj/src/ide-bin/etc/
 Nodal.wsdl

 [java] Caused by : WSDLException (at /wsdl:definitions/wsdl:types/
 xs:schema/xsd:schema/xsd:schema): faultCode=PARSER_ERROR: Problem 
 parsing 'file:/U:/NonVerConPrj/MyProj/src/ide-bin/etc/xmldsig-core-
 schema.xsd'.: java.net.ConnectException: Connection timed out: connect


 Public file references:

 http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-sec
 ext-1.0.xsd , saved locally as 
 oasis-200401-wss-wssecurity-secext-1.0.xsd
 (attached)

 http://www.w3.org/TR/xmldsig-core/xmldsig-core-schema.xsd, saved 
 locally as xmldsig-core-schema.xsd (attached)

 http://www.w3.org/2001/xml.xsd, saved locally as xml.xsd


 Thanks,


 Radu Manolescu
 Morgan Stanley | Technology
 2000 Westchester Ave, 1st Floor | Purchase, NY  10577
 Phone: +1 914 225-5871
 Mobile: +1 203 648-6964
 [EMAIL PROTECTED]

 NOTICE: If received in error, please destroy and notify sender.  
 Sender does not intend to waive confidentiality or privilege. Use of 
 this email is prohibited when received in error.

---
Daniel Kulp
[EMAIL PROTECTED]
http://www.dankulp.com/blog


NOTICE: If received in error, please destroy and notify sender. Sender does not 
intend to waive confidentiality or privilege. Use of this email is prohibited 
when received in error.


Re: WSDLToJava Error | xmldsig-core-schema.xsd | Connection timed out

2008-06-05 Thread Daniel Kulp


On Jun 5, 2008, at 5:09 PM, Manolescu, Radu (IT) wrote:


This was due to a firewall issue. By adding proxy information to the
wsdl2java command line, I was able to move on to more challenging  
error

messages:

java -DproxySet=true -DproxyHost=myProxy.myCompany.com
-DproxyPort=myPort org.apache.cxf.tools.wsdlto.WSDLToJava -d ..
FileName.wsdl

Now I am battling body part errors such as:

In a port, operations must have unique operation signaure on the wire
for successful dispatch.
In port {http://www.myCo.com/wsdl/2007-06/abcd/efgh}HttpEndPoint,
Operations
{http://www.myCo.com/wsdl/2007-06/abcd/efgh}Op1; and
{http://www.myCo.com/wsdl/2007-06/abcd/efgh}Op2;
have the same request body block
{http://www.myCo.com/schema/2007-06/abcd/ews/message}RequestMessage

I assume that we need to contact the web service provider and ask them
to modify the WSDL to have unique signatures for each operation.


Yea.   Most likely.

I've thought about loosening this a little bit, just haven't had  
time.   Right now, we don't check the SOAPAction stuff when we spit  
out that error.   In theory, if the soapactions are unique, we can  
dispatch on it instead of the element name in the body.   The runtime  
already supports doing that, but the tooling doesn't take that into  
account as it strictly evaluates the rules from the WSI-BP compliance  
stuff.   Doing so would require digging into the binding a bit though  
instead of just looking at the logical structures.Not a huge deal,  
but it would require a little bit of work.


Dan







Thanks,


Radu Manolescu
Morgan Stanley | Technology
2000 Westchester Ave, 1st Floor | Purchase, NY  10577
Phone: +1 914 225-5871
Mobile: +1 203 648-6964
[EMAIL PROTECTED]

-Original Message-
From: Daniel Kulp [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 05, 2008 4:57 PM
To: users@cxf.apache.org
Cc: cxf-ea
Subject: Re: WSDLToJava Error | xmldsig-core-schema.xsd | Connection
timed out



If eclipse is having problems reading it, most likely we cannot
either. I'm not exactly sure how you can get a connection timed
out error with a file URL.   That seams a bit strange.   Maybe a
permissions issue?   Is the file really readable?  (can you cat it?
load it in notepad?)

Dan



On Jun 5, 2008, at 11:14 AM, Manolescu, Radu (IT) wrote:

I am trying to generate client code from a WSDL file, and I am  
getting



the error below.
My WSDL references an XSD (authored by our counterpart) which
references the public file oasis-200401-wss-wssecurity-
secext-1.0.xsd, which references the public file xmldsig-core-
schema.xsd.
I tried to use Eclipse to validate the WSDL and XSD files, and when
Eclipse complained that it could not read some XSD files, I  
downloaded



them locally and changed the schemaLocation references accordingly.

The last errors, which I cannot seem to be able to remove, are:
* oasis-200401-wss-wssecurity-secext-1.0.xsd does not pass

Eclipse

validation. Eclipse complains about being unable to read
xmldsig-core-schema.xsd, whether that file is referenced locally or
from the Internet
* when using Ant to call wsdl2java to generate the client, I get

the

exception below. Which program is trying to connect, and where?
Is Ant trying to download files from the Internet while parsing
xmldsig-core-schema.xsd?. If so, how can I make it connect?  
Define a



proxy somewhere? Download the dependencies locally?

wsdl2java:

[java] WSDLToJava Error : java.lang.RuntimeException: Fail to create
wsdl definition from : file:/U:/NonVerConPrj/MyProj/src/ide-bin/etc/
Nodal.wsdl

[java] Caused by : WSDLException (at /wsdl:definitions/wsdl:types/
xs:schema/xsd:schema/xsd:schema): faultCode=PARSER_ERROR: Problem
parsing 'file:/U:/NonVerConPrj/MyProj/src/ide-bin/etc/xmldsig-core-
schema.xsd'.: java.net.ConnectException: Connection timed out:  
connect



Public file references:

http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity- 
sec

ext-1.0.xsd , saved locally as
oasis-200401-wss-wssecurity-secext-1.0.xsd
(attached)

http://www.w3.org/TR/xmldsig-core/xmldsig-core-schema.xsd, saved
locally as xmldsig-core-schema.xsd (attached)

http://www.w3.org/2001/xml.xsd, saved locally as xml.xsd


Thanks,


Radu Manolescu
Morgan Stanley | Technology
2000 Westchester Ave, 1st Floor | Purchase, NY  10577
Phone: +1 914 225-5871
Mobile: +1 203 648-6964
[EMAIL PROTECTED]

NOTICE: If received in error, please destroy and notify sender.
Sender does not intend to waive confidentiality or privilege. Use of
this email is prohibited when received in error.


---
Daniel Kulp
[EMAIL PROTECTED]
http://www.dankulp.com/blog


NOTICE: If received in error, please destroy and notify sender.  
Sender does not intend to waive confidentiality or privilege. Use of  
this email is prohibited when received in error.


---
Daniel Kulp
[EMAIL PROTECTED]
http://www.dankulp.com/blog






Re: WSDLToJava Error: Thrown by JAXB

2008-06-02 Thread Christopher . Mathrusse
It appears that this is not caused by my binding file. When I remove my 
binding file from the build, meaning I don't tell WSDLToJava about my 
binding file, I still receive the error. Do I have a library out of sync 
somewhere?

Chris Mathrusse
[EMAIL PROTECTED]
Sybase, Inc
One Sybase Drive
Dublin, CA 94568
(925) 236-5553



[EMAIL PROTECTED] 
06/02/2008 02:50 PM
Please respond to
users@cxf.apache.org


To
users@cxf.apache.org
cc

Subject
WSDLToJava Error: Thrown by JAXB






I'm attempting to upgrade from the CXF incubator project to CXF 2.1. I've 
managed to get my server up and running with the web services exposed 
successfully, but when I attempt to generate the client files using 
WSDLToJava I received the following exception:

 [java] WSDLToJava Error: Thrown by JAXB : JAXB version attribute must 

be 1.0

I am using binding files so I can override the Date and Calendar objects, 
but these are basically right out of the documentation.

jaxws:bindings wsdlLocation=
http://localhost:8080/QuoteService/services/CosmosBroker?wsdl;
  xmlns:jaxws=http://java.sun.com/xml/ns/jaxws;
  xmlns:xs=http://www.w3.org/2001/XMLSchema;
  xmlns:jxb=http://java.sun.com/xml/ns/jaxb;
  xmlns:wsdl=http://schemas.xmlsoap.org/wsdl/; jxb:version=1.0
  jaxws:bindings node=
wsdl:definitions/wsdl:types/xs:[EMAIL PROTECTED]'http://cosmos.it.sybase.com']

  jxb:globalBindings xmlns:jxb=http://java.sun.com/xml/ns/jaxb; 
xmlns:xs=http://www.w3.org/2001/XMLSchema;
jxb:serializable/
jxb:javaType name=java.util.Date xmlType=xs:dateTime
  parseMethod=
org.apache.cxf.tools.common.DataTypeAdapter.parseDateTime
  printMethod=
org.apache.cxf.tools.common.DataTypeAdapter.printDateTime/
  /jxb:globalBindings
  /jaxws:bindings
/jaxws:bindings


Any idea as to how I can get around this issue?

Thanks...