On Thursday 11 December 2008 3:23:19 am D Mazza wrote: > Hi Dan, > thank you for the answer. > > Should asm.jar cause the error to go away? > > I tried with asm-2.2.3 but I still have the exception. > > Any other solution, other than using CXF 2.0.9 instead of 2.1.3? Should I > expect that future releases (2.1.x) might work with these objects?
I deployed a new 2.1.4-SNAPSHOT yesterday that MAY help. It's really a JAXB issue though and I'm not sure what can be done about it. CXF 2.0.x uses JAXB 2.0.5 which treats objects that don't have a defined targetNamespace a bit differently than JAXB 2.1.x. I'm trying to detect some of this in the schemas that have been returned from JAXB and trying to do some correction on them, but it's probably not completely doable. With the 2.1.4-SNAPSHOT, what I THINK should occur is it will generate the WSDL/Schema OK so ?wsdl will not throw the exception. However, the resulting wsdl/schema may look "funny". Probably with two schemas with the same targetNamespace, but different qualifiers and such. That's usually an indication that the object model has something "not quite right". Look at the types (and package-info.java) defined in the two schemas to see if something about those types is not right. (like a missing @XmlType or missing targetNamespace attributes or similar) Dan > > Davide > > dkulp wrote: > > Just to follow up on this on list so future searches might find a > > solution..... > > > > In this particular case, adding asm.jar to the classpath caused the error > > to > > go away. > > > > HOWEVER, the root cause of the problem seems to be an invalid JAXB object > > model that is creating some strange schemas and then an invalid wsdl. > > I've > > made some changes on trunk/2.1.x to allow it to put all the schemas into > > the > > wsdl, even if they aren't quite "correct". At the vary least, it allows > > you > > to look at it which may help diagnose what object in the graph is causing > > issues. In his case, ONE type in the entire context of a bunch of > > objects > > didn't have a proper XmlType annotation which then caused some default > > namespace schemas to be created for it that conflicted with other types > > and > > such. > > > > Dan > > > > On Wednesday 10 December 2008 9:45:19 am D Mazza wrote: > >> Dear all, > >> I'm using CXF 2.1.3. WSDL generation fails with the following exception: > >> org.apache.cxf.transport.http.WSDLQueryException: Exception occurred > >> while > >> trying to process .../services/address?wsdl > >> at > >> org.apache.cxf.transport.http.WSDLQueryHandler.writeResponse(WSDLQueryHa > >>ndl er.java:214) at > >> org.apache.cxf.transport.servlet.ServletController.invoke(ServletControl > >>ler .java:154) at > >> org.apache.cxf.transport.servlet.AbstractCXFServlet.invoke(AbstractCXFSe > >>rvl et.java:175) at > >> org.apache.cxf.transport.servlet.AbstractCXFServlet.doGet(AbstractCXFSer > >>vle t.java:157) at > > javax.servlet.http.HttpServlet.service(HttpServlet.java:743) > > >> Truncated. see log file for complete stacktrace > >> javax.wsdl.WSDLException: WSDLException: faultCode=OTHER_ERROR: Can't > >> find > >> prefix for 'http://www.csapi.org/schema/parlayx/group_mgmt/v3_0/local'. > >> Namespace prefixes must be set on the Definition object using the > >> addNamespace(...) method. > >> at com.ibm.wsdl.util.xml.DOMUtils.getPrefix(Unknown Source) > >> at com.ibm.wsdl.util.xml.DOMUtils.getQualifiedValue(Unknown Source) > >> at com.ibm.wsdl.util.xml.DOMUtils.printQualifiedAttribute(Unknown > >> Source) > >> at com.ibm.wsdl.xml.WSDLWriterImpl.printParts(Unknown Source) > >> at com.ibm.wsdl.xml.WSDLWriterImpl.printMessages(Unknown Source) > >> > >> The problem seems to be that @WebParameter declares a different target > >> namespace than service. > >> Please find Spring configuration file, service interface and impl > >> attached. > >> http://www.nabble.com/file/p20936036/applicationContext.xml > >> applicationContext.xml > >> http://www.nabble.com/file/p20936036/GroupManagement.java > >> GroupManagement.java > >> http://www.nabble.com/file/p20936036/GroupManagementServiceImpl.java > >> GroupManagementServiceImpl.java > >> > >> Any ideas? I read that XFire had a bug related to this issue. Could it > >> be the same? Or some configuration is needed? > >> > >> Regards > >> DAvide > > > > -- > > Daniel Kulp > > [EMAIL PROTECTED] > > http://dankulp.com/blog -- Daniel Kulp [EMAIL PROTECTED] http://dankulp.com/blog
