You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Erwin Liem (JIRA)" <ji...@apache.org> on 2011/07/01 15:08:28 UTC

[jira] [Commented] (AXIS2-5083) XmlSchemaException: problem with target namespace

    [ https://issues.apache.org/jira/browse/AXIS2-5083?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13058542#comment-13058542 ] 

Erwin Liem commented on AXIS2-5083:
-----------------------------------

*** NOTICE ***

Actually I could change the namespace within xsd from http://DEF to http://ABC, but I want to avoid this, so that the external schema has its own namespace and it can be neutrally included into another WSDL.

> XmlSchemaException: problem with target namespace
> -------------------------------------------------
>
>                 Key: AXIS2-5083
>                 URL: https://issues.apache.org/jira/browse/AXIS2-5083
>             Project: Axis2
>          Issue Type: Bug
>          Components: wsdl
>    Affects Versions: 1.5.5
>         Environment: java version "1.6.0_22"
> OpenJDK Runtime Environment (IcedTea6 1.10.2) (6b22-1.10.2-0ubuntu1~11.04.1)
> OpenJDK 64-Bit Server VM (build 20.0-b11, mixed mode)
> Linux C-3PO 2.6.38-8-generic #42-Ubuntu SMP Mon Apr 11 03:31:24 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux
>            Reporter: Erwin Liem
>
> I currently have a WSDL and want to have the client stub based on Axis2. But Axis2 cannot generate it, because of the conflict of the target namespaces:
> [ERROR] org.apache.ws.commons.schema.XmlSchemaException: An included schema was announced to have the default target namespace or the target namespace http://ABC, but has the target namespace http://EFG
> But it is very strange, since Axis1.4 generates the stub without errors. I also use SoapUI 3.6.1 and with this tool I don't get error either. Maybe the snippet below could help to illustrate how my WSDL (rpc/literal) + schema look like:
> ***************wsdl*************
> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
> <wsdl:definitions xmlns:crm1="http://DEF" xmlns:crm="http://ABC" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="crmWS" targetNamespace="http://ABC">
>    <wsdl:types>
>       <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ABC">
>          <xsd:include schemaLocation="singleTypes.xsd"/>
>          <xsd:complexType name="request">
>             <xsd:sequence>
>                <xsd:element ref="crm1:companyName" minOccurs="0" maxOccurs="1"/>
> ...
> ***************xsd*************
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://DEF">
>    <!-- common header elements -->
>    <xsd:element name="customerID" type="xsd:integer"/>
>    <xsd:element name="customerUserID" type="xsd:string"/>
>    .....
> I've been facing this problem since days and still have found no solution. Can anybody help me?

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: java-dev-help@axis.apache.org