[
https://issues.apache.org/jira/browse/AXIS2-4143?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12649719#action_12649719
]
dlindquist edited comment on AXIS2-4143 at 11/21/08 10:01 AM:
------------------------------------------------------------------
(Attached file 'bad.wsdl')
This is an example (completely fictitious) WSDL that causes the error to occur.
See the:
<xsd:element name="thing">
<xsd:complexType>
<xsd:simpleContent>
<xsd:extension base="xsd:string">
</xsd:extension>
</xsd:simpleContent>
</xsd:complexType>
</xsd:element>
declaration within the
<xsd:complexType name="Test">
entry for the portion that causes the problem.
was (Author: dlindquist):
This is an example (completely fictitious) WSDL that causes the error to
occur. See the:
<xsd:element name="thing">
<xsd:complexType>
<xsd:simpleContent>
<xsd:extension base="xsd:string">
</xsd:extension>
</xsd:simpleContent>
</xsd:complexType>
</xsd:element>
declaration within the
<xsd:complexType name="Test">
entry for the portion that causes the problem.
> Type.Property (ex A.B) and Type (ex AB) Names Collide in Object Factory
> (jaxbri Code Generation) -- Two declarations cause a collision in the
> ObjectFactory class
> -----------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: AXIS2-4143
> URL: https://issues.apache.org/jira/browse/AXIS2-4143
> Project: Axis 2.0 (Axis2)
> Issue Type: Bug
> Components: codegen
> Affects Versions: 1.4.1
> Environment: Windows XP (x86), Apache Axis2 1.4.1, Sun JDK 1.5.0_12
> Reporter: Dave Lindquist
> Priority: Minor
> Attachments: bad.wsdl, ok.wsdl
>
>
> When using JAXBRI bindings and generating from a WSDL via wsdl2java.bat, it
> is possible for a Type.Property and Type name to collide in ObjectFactory.
> For example, if my XSD has:
> * A type named "Something"
> * A type named "Some" with a property named "thing" (and this property is
> also an "anonymous" complex type)
> I will get an error on code generation that says:
> [ERROR] Two declarations cause a collision in the ObjectFactory class.
> [ERROR] (Related to above error) This is the other declaration.
> 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(CodeGenerationEngine.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.InvocationTargetException
> at
> org.apache.axis2.wsdl.codegen.extension.JAXBRIExtension.engage(JAXBRIExtension.java:112)
> at
> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:224)
> ... 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.JAXBRIExtension.engage(JAXBRIExtension.java:101)
> ... 3 more
> Caused by: java.lang.RuntimeException: java.lang.RuntimeException: Unable to
> generate code using jaxbri
> at
> org.apache.axis2.jaxbri.CodeGenerationUtility.processSchemas(CodeGenerationUtility.java:304)
> ... 8 more
> Caused by: java.lang.RuntimeException: Unable to generate code using jaxbri
> at
> org.apache.axis2.jaxbri.CodeGenerationUtility.processSchemas(CodeGenerationUtility.java:196)
> ... 8 more
> The bug here is two-fold:
> * First, I get absolutely nothing in terms of information that helps me track
> down WHAT declarations collided (the second message line looks like it was
> intending to provide that, but it doesn't).
> * Secondly, that it collides at all (this is a perfectly valid case, and
> should be handled in codegen).
> I will attach example WSDLs that create this case when generated.
> The command line used is:
> wsdl2java.bat -o (output directory) -b jaxbri -uri (wsdl file)
--
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]