There are multiple wsdl files provided by yahoo. The reason -p option is used is to create a package for each of the service. If the -p option is not use the ws2dltojava keeps overwriting the ObjectFactory.java. Could you suggest me the solution for this
nmt dkulp wrote: > > > > I believe 2.1.4 would show the same error. > > Basically, the -p option is NOT safe to use if there are multiple schemas. > Previously, we didn't catch that and the generated code would "randomly > work" > and "randomly not work" which is not good. It's basically a JAXB issue. > JAXB needs each schema to get generated into it's own package so that it > can > have a package-info.java and ObjectFactory.java per schema. > > Dan > > > > On Thu March 26 2009 2:04:06 pm nmt999 wrote: >> Hi >> >> The command >> wsdl2java -p com.test.appl.service -d build -exsh true -verbose -b >> ServiceBinding.xml TheService.wsdl >> works with wsdl2java - Apache CXF 2.1.3 but gives the error below when >> used >> with >> >> [java] wsdl2java - Apache CXF 2.2 >> [java] WSDLToJava Error: -p option cannot be used when wsdl contains >> mutiple schemas >> [java] org.apache.cxf.tools.common.ToolException: -p option cannot >> be >> used when wsdl contains mutiple schemas >> [java] at >> org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer >>.java:175) [java] at >> org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer >>.java:238) [java] at >> org.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java:83) >> [java] at >> org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:103) >> [java] at >> org.apache.cxf.tools.wsdlto.WSDLToJava.main(WSDLToJava.java:173) >> >> Nothing else changed only the cxf jars have changed to use the newer >> version. >> >> nmt > > -- > Daniel Kulp > [email protected] > http://www.dankulp.com/blog > > -- View this message in context: http://www.nabble.com/wsdl2java-error-when-change-version-from-2.1.3-to-2.2-tp22727714p22728206.html Sent from the cxf-user mailing list archive at Nabble.com.
