axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dave James (JIRA)" <>
Subject [jira] Commented: (AXIS2-1790) schemaLocation element of import statements should contain URI reference to schema document.
Date Thu, 04 Sep 2008 21:53:44 GMT


Dave James commented on AXIS2-1790:


I'm working with Axis2 1.4, I've tried making the changes and building the kernel jar, but
I get the following error:

generics are not supported in -source 1.4
(use -source 5 or higher to enable generics)
        private CopyOnWriteArrayList<MessageContextListener> messageContextListeners
= new CopyOnWriteArrayList<MessageContextListener>()

I'm pretty sure I'm not going to be able to use a version other than 1.4 at the moment, any


> schemaLocation element of import statements should contain URI reference to schema document.
> --------------------------------------------------------------------------------------------
>                 Key: AXIS2-1790
>                 URL:
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Improvement
>          Components: wsdl
>    Affects Versions: 1.1
>         Environment: Windows XP, Java 5 Update 9
>            Reporter: Aaron Gourley
>            Assignee: Deepal Jayasinghe
>         Attachments: axis2-kernel-SNAPSHOT.jar, schema-import-generation.patch, XsdAndWsdlImportTestService.aar
> From W3C schemaLocation spec:
> Additional reference:
> <import
>   id = ID
>   namespace = anyURI
>   schemaLocation = anyURI
>   {any attributes with non-schema namespace . . .}>
>   Content: (annotation?)
> </import>
> "In a schema, the  include element has a required schemaLocation  attribute, and it contains
a URI reference which must identify a schema document."
> Axis2 is currently using a relative SchemaLocation, which on its own can not be used
to identify the schema document.  This actually causes a compatibility problem between Glue
clients and such WSDLs published by Axis2.
> WSDL published by Axis2:
> <wsdl:definitions targetNamespace="">
> <wsdl:documentation>TerminalLocation</wsdl:documentation>
>     <wsdl:types>
>         <xsd:schema attributeFormDefault="unqualified" elementFormDefault="qualified"
>             <xsd:import namespace=""
>             <xsd:import namespace=""
>      .....
>     <wsdl:service name="TerminalLocation">
>         <wsdl:port name="TerminalLocationSOAP11port_http" binding="tns:TerminalLocationSOAP11Binding">
>             <soap:address location="http://localhost:9080/TerminalLocationService/services/TerminalLocation"/>
>         </wsdl:port>
>         <wsdl:port name="TerminalLocationSOAP12port_http" binding="tns:TerminalLocationSOAP12Binding">
>             <soap12:address location="http://localhost:9080/TerminalLocationService/services/TerminalLocation"/>
>         </wsdl:port>
>         <wsdl:port name="TerminalLocationHttpport1" binding="tns:TerminalLocationHttpBinding">
>             <http:address location="http://localhost:9080/TerminalLocationService/rest/TerminalLocation"/>
>         </wsdl:port>
>     </wsdl:service>
> </wsdl:definitions>
> When Glue parses this WSDL, it simply creates a URI from the string "TerminalLocation?xsd=xsd0".
 Since the prefix ("http://localhost:9080/TerminalLocationService/services/") is not shown
in the WSDL, a FileNotFoundException occurs and the bind fails.  I have not been able to find
a workaround using Glue.
> I realize that the easy solution is to say that this is a Glue problem, but would it
be at all possible to include the address location in the generated WSDL?
> Suggested fix:
> 1. In AxisService's adjustSchemaLocation(XmlSchema, XmlSchemaExternal, Hashtable, Hashtable)
>     - Change getName() in default mode to getEndpoint()
> 2. In AxisService2WSDL2's generateOM() method:
>     - add call to axisService.setCustomSchemaNamePrefix(axisService.getEndpoint() + "?xsd=")
before call to populateSchemaMappings() is made.

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:
For additional commands, e-mail:

View raw message