[ https://issues.apache.org/jira/browse/AXIS2C-1121?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor resolved AXIS2C-1121. -------------------------- Resolution: Fixed Fix Version/s: Current (Nightly) Problems with WSDL2C generator resolved in nightly release. But my wish is to add WSDL2C generator in Axis2C release (not only to Axis2 java). > Exception in thread "main" > org.apache.axis2.wsdl.codegen.CodeGenerationException > -------------------------------------------------------------------------------- > > Key: AXIS2C-1121 > URL: https://issues.apache.org/jira/browse/AXIS2C-1121 > Project: Axis2-C > Issue Type: Bug > Components: code generation > Affects Versions: 1.3.0 > Environment: windows, axis2 1.3 > Reporter: Igor > Fix For: Current (Nightly) > > > I have an error in generating C-code from my wsdl-file. > Simply i created my-WS-Resource.wsdl and import > wsrf-WS-ResourceProperties-1.2-draft-01.wsdl/ > File: > <?xml version="1.0" encoding="utf-8"?> > <wsdl:definitions name="AnyResource-ResourceProperties" > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap" > xmlns:xsd="http://www.w3.org/2001/XMLSchema" > xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/03/addressing" > > xmlns:wsbf="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-BaseFaults-1.2-draft-01.xsd" > > xmlns:wsrp="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.xsd" > > > xmlns:wsrpw="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.wsdl" > > targetNamespace="przanyresource" > xmlns:przanyresource="przanyresource" > > <wsdl:import > > namespace="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.wsdl" > location="wsrf-WS-ResourceProperties-1.2-draft-01.wsdl"/> > > <!-- ===================== Types Definitions ====================== --> > <wsdl:types> > <xsd:schema targetNamespace="przanyresource" > > xmlns:wsrpw="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.wsdl"> > <xsd:element name="AnyResourceProperties" type:"xsd:anyType"> > > </xsd:schema> > </wsdl:types> > <wsdl:portType name="AnyResource_PortType" > wsrp:ResourceProperties="przanyresource:AnyResourceProperties"> > > <wsdl:operation name="GetResourceProperty"> > <wsdl:input name="GetResourcePropertyRequest" > message="wsrpw:GetResourcePropertyRequest" /> > <wsdl:output name="GetResourcePropertyResponse" > message="wsrpw:GetResourcePropertyResponse" /> > <wsdl:fault name="InvalidResourcePropertyQNameFault" > message="wsrpw:InvalidResourcePropertyQNameFault"/> > <wsdl:fault name="ResourceUnknownFault" > message="wsrpw:ResourceUnknownFault"/> > > </wsdl:operation> > </wsdl:portType> > <wsdl:binding name="AnyResourceBinding" > type="przanyresource:AnyResource_PortType"> > <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> > <wsdl:operation name="GetResourceProperty"> > <soap:operation soapAction="GetResourceProperty" style="document" /> > <wsdl:input> > <soap:body use="literal" namespace="przanyresource" /> > </wsdl:input> > <wsdl:output> > <soap:body use="literal" namespace="przanyresource" /> > </wsdl:output> > </wsdl:operation> > </wsdl:binding> > <wsdl:service name="AnyResourceService"> > <wsdl:port name="AnyResourcePort" > binding="przanyresource:AnyResourceBinding"> > <soap:address location="http://localhost/service" /> > </wsdl:port> > </wsdl:service> > </wsdl:definitions> > Error: > [INFO] A SOAP port was not found - picking a random port! > 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:265) > at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:35) > at org.apache.axis2.wsdl.WSDL2C.main(WSDL2C.java:31) > 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:218) > ... 2 more > Caused by: java.lang.reflect.InvocationTargetException > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) > at java.lang.reflect.Method.invoke(Unknown Source) > 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.CStructWriter.write(CStructWriter.java > :200) > at > org.apache.axis2.schema.SchemaCompiler.writeComplexType(SchemaCompile > r.java:934) > at > org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler. > java:563) > at > org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler. > java:478) > at > org.apache.axis2.schema.SchemaCompiler.process(SchemaCompiler.java:18 > 99) > at > org.apache.axis2.schema.SchemaCompiler.processParticle(SchemaCompiler > .java:1788) > at > org.apache.axis2.schema.SchemaCompiler.processComplexType(SchemaCompi > ler.java:977) > at > org.apache.axis2.schema.SchemaCompiler.processNamedComplexSchemaType( > SchemaCompiler.java:914) > at > org.apache.axis2.schema.SchemaCompiler.processSchema(SchemaCompiler.j > ava:865) > at > org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler. > java:518) > at > org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler. > java:489) > at > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:30 > 2) > at > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:28 > 4) > at > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:21 > 2) > at > org.apache.axis2.schema.ExtensionUtility.invoke(ExtensionUtility.java > :80) > Caused by: java.lang.NullPointerException > at > org.apache.axis2.schema.writer.CStructWriter.addPropertyEntries(CStru > ctWriter.java:618) > at > org.apache.axis2.schema.writer.CStructWriter.populateInfo(CStructWrit > er.java:508) > at > org.apache.axis2.schema.writer.CStructWriter.getBeanElement(CStructWr > iter.java:431) > at > org.apache.axis2.schema.writer.CStructWriter.process(CStructWriter.ja > va:320) > at > org.apache.axis2.schema.writer.CStructWriter.write(CStructWriter.java > :195) > ... 22 more > After that i tried to generate CPP-code by AxisC wsdl2ws generator and have > error: > org.apache.axis.wsdl.wsdl2ws.WrapperFault: Unregistered type > {http://docs.oasis- > open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.wsdl}GetResourcePr > opertyResponseType referred > at > org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.addDocumentStyleOutputMessageToM > ethodInfo(Unknown Source) > at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.setMethodInfo(Unknown Source) > at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.getServiceInfo(Unknown Source) > at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.generateWrappers(Unknown > Source) > at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.main(Unknown Source) > I think the problem in portType element with message > "wsrpw:GetResourcePropertyResponse". It is imported from > wsrf-WS-ResourceProperties-1.2-draft-01.wsdl file. > <wsdl:portType name="AnyResource_PortType" > wsrp:ResourceProperties="przanyresource:AnyResourceProperties"> > > <wsdl:operation name="GetResourceProperty"> > <wsdl:input name="GetResourcePropertyRequest" > message="wsrpw:GetResourcePropertyRequest" /> > <wsdl:output name="GetResourcePropertyResponse" > message="wsrpw:GetResourcePropertyResponse" /> > <wsdl:fault name="InvalidResourcePropertyQNameFault" > message="wsrpw:InvalidResourcePropertyQNameFault"/> > <wsdl:fault name="ResourceUnknownFault" > message="wsrpw:ResourceUnknownFault"/> > > </wsdl:operation> > </wsdl:portType> > May be i made a mistake in my WSDL? -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]