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 "Amila Chinthaka Suriarachchi (JIRA)" <ji...@apache.org> on 2007/06/11 23:58:25 UTC

[jira] Commented: (AXIS2-2774) Lack of support for XML Schema Inheiritance

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

Amila Chinthaka Suriarachchi commented on AXIS2-2774:
-----------------------------------------------------

What is the databinding frame work you use?
If it is ADB, then you are correct ADB does not support abstract = 'true'. But it does support complex type extensions(i.e polymorphisum)

> Lack of support for XML Schema Inheiritance
> -------------------------------------------
>
>                 Key: AXIS2-2774
>                 URL: https://issues.apache.org/jira/browse/AXIS2-2774
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: codegen
>    Affects Versions: 1.2
>         Environment: Windows
>            Reporter: Raine Fujisama
>            Assignee: Amila Chinthaka Suriarachchi
>            Priority: Blocker
>         Attachments: ConsumerManagerTrial3.wsdl
>
>
> I wrote a WSDL, ran wsdl2java.bat to generate server side code.  Compiled.  Build the aar and deployed it in tomcat.
> I then sent it a couple sample soap files and got unexpected results.  This makes me think that some of the xsd features I used are not supported by Axis, namely the abstract attribute and inheiritance of complex types.  Can someone confirm my suspicions or tell me where I'm going wrong?
> The first message I sent was:
> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:m0="http://consumermgr.sss.com/consumermgr">
>     <SOAP-ENV:Body>
>         <m:addDevice xmlns:m="http://consumermgr.sss.com" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
>             <addDeviceInputParam>
>                 <m0:header>
>                     <m0:timestamp>2001-12-17T09:30:47.0Z</m0:timestamp>
>                     <m0:fromId>0</m0:fromId>
>                 </m0:header>
>                 <m0:deviceId>
>                     <m0:idType/>
>                     <m0:id/>
>                 </m0:deviceId>
>                 <m0:attributes></m0:attributes>/>
>             </addDeviceInputParam>
>         </m:addDevice>
>     </SOAP-ENV:Body>
> </SOAP-ENV:Envelope>
> The response I got was:
> <?xml version="1.0" encoding="UTF-8"?>
> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
>     <soapenv:Body>
>         <soapenv:Fault>
>             <faultcode>soapenv:Client</faultcode>
>             <faultstring>Please implement com.sss.consumermgr.consumermgr.ConsumerMgrServiceSkeleton#addDevice</faultstring>
>             <detail/>
>         </soapenv:Fault>
>     </soapenv:Body>
> </soapenv:Envelope>
> apparently meaning that the soap message was validated.  How can this be?!  m0:attributes is defined as a complextype for which abstract="true".  That means that it is invalid for it to appear in an actual instance!  Is the abstract attribute not supported by Axis???
> The second soap message I sent was:
> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:m0="http://consumermgr.sss.com/consumermgr">
>     <SOAP-ENV:Body>
>         <m:addDevice xmlns:m="http://consumermgr.sss.com" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
>             <addDeviceInputParam>
>                 <m0:header>
>                     <m0:timestamp>2001-12-17T09:30:47.0Z</m0:timestamp>
>                     <m0:fromId>0</m0:fromId>
>                 </m0:header>
>                 <m0:deviceId>
>                     <m0:idType/>
>                     <m0:id/>
>                 </m0:deviceId>
>                 <m0:attributes xsi:type="STBAttributeSetType"><m0:password>MyPW</m0:password></m0:attributes>/>
>             </addDeviceInputParam>
>         </m:addDevice>
>     </SOAP-ENV:Body>
> </SOAP-ENV:Envelope>
> The Response was:
> <?xml version="1.0" encoding="UTF-8"?>
> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
>     <soapenv:Body>
>         <soapenv:Fault>
>             <faultcode>soapenv:Client</faultcode>
>             <faultstring>java.lang.RuntimeException: Unsupported type null STBAttributeSetType</faultstring>
>             <detail/>
>         </soapenv:Fault>
>     </soapenv:Body>
> </soapenv:Envelope>
> Now in my schema STBAttributeSetType is defined as extending an abstract complex type.  <attributes> is of type that abstract type.  Therefore the axis-generated server code should like STBAttributeSetType.  Does the "Unsupported type" error it returns mean that axis doesn't support complextype inheiritance?

-- 
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: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org