This seems to be an ADB problem which caused by your schemas. Please log a jira with the wsdl .xsd files to reproduce the issue.
thanks, Amila. On Sun, Nov 30, 2008 at 8:02 PM, Néstor Boscán <[EMAIL PROTECTED]> wrote: > Used other data bindings and I'm having validation problems with xmlbeans > and jaxb. But they seem to read the xsd files. I even used xjc.bat and > scomp.bat directly and it works. > > > > What is strange is that it does detect the xsd files because it shows: > > > > Retrieving schema at 'file2.xsd', relative to 'file1.xsd'. > > > > And it loads every file. Then it shows the TYPE Warnings. And at the end I > get an exception: > > > > Exception in thread "main" > org.apache.axis2.wsdl.codegen.CodeGenerationException > > : java.lang.RuntimeException: java.lang.reflect.InvocationTargetException > > at > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGener > > ationEngine.java:271) > > at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:35) > > at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:24) > > Caused by: java.lang.RuntimeException: > java.lang.reflect.InvocationTargetExcepti > > on > > at > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(Simp > > leDBExtension.java:53) > > at > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGener > > ationEngine.java:224) > > ... 2 more > > Caused by: java.lang.reflect.InvocationTargetException > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. > > java:39) > > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces > > sorImpl.java:25) > > at java.lang.reflect.Method.invoke(Method.java:597) > > at > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(Simp > > leDBExtension.java:50) > > ... 3 more > > Caused by: org.apache.axis2.schema.SchemaCompilationException: > java.lang.NullPoi > > nterException > > at > org.apache.axis2.schema.writer.JavaBeanWriter.write(JavaBeanWriter.ja > > va:270) > > at > org.apache.axis2.schema.SchemaCompiler.writeComplexType(SchemaCompile > > r.java:1037) > > at > org.apache.axis2.schema.SchemaCompiler.processNamedComplexSchemaType( > > SchemaCompiler.java:1023) > > at > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:39 > > 5) > > at > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:35 > > 2) > > at > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:35 > > 2) > > at > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:28 > > 0) > > at > org.apache.axis2.schema.ExtensionUtility.invoke(ExtensionUtility.java > > :103) > > ... 8 more > > Caused by: java.lang.NullPointerException > > at > org.apache.axis2.schema.writer.JavaBeanWriter.typeChanged(JavaBeanWri > > ter.java:1100) > > at > org.apache.axis2.schema.writer.JavaBeanWriter.addPropertyEntries(Java > > BeanWriter.java:776) > > at > org.apache.axis2.schema.writer.JavaBeanWriter.populateInfo(JavaBeanWr > > iter.java:695) > > at > org.apache.axis2.schema.writer.JavaBeanWriter.getBeanElement(JavaBean > > Writer.java:602) > > at > org.apache.axis2.schema.writer.JavaBeanWriter.process(JavaBeanWriter. > > java:460) > > at > org.apache.axis2.schema.writer.JavaBeanWriter.write(JavaBeanWriter.ja > > va:265) > > ... 15 more > > > > Regards, > > > > Néstor Boscán > > > > *De:* Amila Suriarachchi [mailto:[EMAIL PROTECTED] > *Enviado el:* Sunday, November 30, 2008 1:36 AM > *Para:* [email protected] > *Asunto:* Re: Type "X" missing > > > > > > On Sun, Nov 30, 2008 at 7:57 AM, Néstor Boscán <[EMAIL PROTECTED]> wrote: > > Hi > > > > I have a lot of xsd files and I need to create a Web Service based on types > stored in those files. I created the wsdl file: > > > > <definitions > > name="myWebService" > > targetNamespace="http://company.com.ve/MY" > > xmlns="http://schemas.xmlsoap.org/wsdl/" > > xmlns:tns="http://company.com.ve/MY" > > xmlns:xsd="http://www.w3.org/2001/XMLSchema" > > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" > > xmlns:my="http://company.com.ve/MY" > > <types> > > <xsd:schema targetNamespace="urn:my"> > > <xsd:import namespace="http://company.com.ve/MY" > schemaLocation="my.xsd"/> > > </xsd:schema> > > </types> > > <message name="my_request"> > > <part name="parameters" element="my:Request"/> > > </message> > > <message name="my_response"> > > <part name="parameters" element="my:Response"/> > > </message> > > <portType name="myWebService"> > > <operation name="my"> > > <input message="tns:my_request"/> > > <output message="tns:my_response"/> > > </operation> > > </portType> > > <binding name="myWebServiceBinding" type="tns:myWebService"> > > <soap:binding style="document" transport=" > http://schemas.xmlsoap.org/soap/http"/> > > <operation name="my"> > > <soap:operation soapAction="http://company.com.ve/my"/> > > <input> > > <soap:body use="literal"/> > > </input> > > <output> > > <soap:body use="literal"/> > > </output> > > </operation> > > </binding> > > <service name="myWebService"> > > <port name="myWebServicePort" binding="tns:myWebServiceBinding"> > > <soap:address location="http://host:port/ "/> > > </port> > > </service> > > </definitions> > > > > When I use wsdl2java I get a lot of Type X is missing on types of xsd files > that are referenced by my.xsd. I tried importing every xsd file and I still > get the error. What am I doing wrong? > > > Try to find the places where type X is used. Then see whether type X is > visible to those places through imports. if you use ADB try to use other > data bindings as well. > eg -d xmlbeans, -d jaxbri > > thanks, > Amila. > > > > Regards, > > > > Néstor Boscán > > > > > -- > Amila Suriarachchi > WSO2 Inc. > blog: http://amilachinthaka.blogspot.com/ > -- Amila Suriarachchi WSO2 Inc. blog: http://amilachinthaka.blogspot.com/
