[wsf-c-dev] [jira] Resolved: (WSFPHP-276) schema import /include doesn't work some time - depends on the appendChild works

Dimuthu Gamage (JIRA) jira at wso2.org
Wed Jul 23 22:37:52 PDT 2008


     [ https://wso2.org/jira/browse/WSFPHP-276?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dimuthu Gamage resolved WSFPHP-276.
-----------------------------------

    Resolution: Won't Fix

This happens because the way php dom appendChild work, and we don't have much control on that. and we don't have immediate plan to change this from append child, so i will mark this as won't fix.

This issue happens very rarely. And most importantly simple change in WSDL will be able to make it working in our implementation. 

> schema import /include doesn't work some time - depends on the appendChild works
> --------------------------------------------------------------------------------
>
>                 Key: WSFPHP-276
>                 URL: https://wso2.org/jira/browse/WSFPHP-276
>             Project: WSO2 WSF/PHP
>          Issue Type: Bug
>          Components: WSDL Mode
>         Environment: Linux + windows
>            Reporter: Dimuthu Gamage
>            Assignee: Dimuthu Gamage
>             Fix For: 2.0.0
>
>
> Schema import in wsf/php completely depends on how appendChild works. In theory if imported schema is added to the original wsdl (we add all to one wsdl to parse it with xslt templates) it should work.
> E.x.
> the following schema
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://test" targetNamespace="http://test">
>     <xsd:element ref="me"/>
>     <xsd:element name="me" type="xsd:int"/>
> </xsd:schema>
>  can be added in to 
> <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <wsdl:types>
> <!--adding to here-->
> </wsdl:types>
> </wsdl:definitions>
> straight away , and theoretically it should work.
> We use PHP DOM appendChild function to this work. But appendChild do some optimization so duplicate namespaces are not re-declared. (this happen only with some conditions). This leads to change in prefixes of some namespaces, or sometime loose prefixes. 
> The problem is 
> 1. if some elements referring to other elements with such a changing prefix,  it will not identify the actual object.
> 2. if the namespace prefix is used only inside ref attribute, dom thinks the prefix is never used and ignore that.
> For an example for above schema php generates following wsdl
> <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <wsdl:types>
> <xsd:schema targetNamespace="http://test">
>     <xsd:element ref="me"/>
>     <xsd:element name="me" type="xsd:int"/>
> </xsd:schema>
> </wsdl:types>
> </wsdl:definitions>
> This is not the same wsdl that we hope to get, the appendChild have ignored the default namespace declaration in addition to the xsd: namespace declaration. 
> This should be fixed to get some wsdls working :(

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://wso2.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the Wsf-c-dev mailing list