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 "Ashutosh Shahi (JIRA)" <ax...@ws.apache.org> on 2004/11/05 06:46:33 UTC
[jira] Commented: (AXIS-1407) Axis not serializing derived classes appropriately
[ http://nagoya.apache.org/jira/browse/AXIS-1407?page=comments#action_55076 ]
Ashutosh Shahi commented on AXIS-1407:
--------------------------------------
Sarvanan,
Can u pass on your client code which you used? I am looking into the issue and unable to reproduce it.
Thanks,
Ashutosh
> Axis not serializing derived classes appropriately
> --------------------------------------------------
>
> Key: AXIS-1407
> URL: http://nagoya.apache.org/jira/browse/AXIS-1407
> Project: Axis
> Type: Bug
> Components: Serialization/Deserialization
> Versions: 1.2 Beta
> Environment: Windows 2000; Netbeans 3.6; iPlanet WebServer 6.1
> Reporter: Saravanan Markandeyan
> Priority: Critical
> Attachments: sample.zip
>
> Axis 1.2 beta is not returning derived class names in the multiRefs as it used to
> in Axis 1.1. Any input on this would be great; is this a known issue?
> Abstract Example below illustrates the issue:
> public class A
> {
> private String amember1;
> }
> public class B extends A
> {
> private String bmember1;
> private String bmember2;
> }
> public class C extends A
> {
> private String cmember1;
> private String cmember2;
> }
> public class ContainerClass
> {
> private A aInstance;
> }
> Suppose the reference of aInstance in an instance of the ContainerClass was set to an instance of Class C and sent across.
> ------------ Axis 1.1 Multiref section ---------------------
> <multiRef id="id7" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
> xsi:type="ns7:ContainerClass"
> xmlns:ns7="http://namespace.ws"
> xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> <aInstance href="#id14"/>
> </multiRef>
> <multiRef id="id14" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
> xsi:type="ns7:C" // THIS WORKS GREAT, SINCE aInstance had a reference to an instance of C
> xmlns:ns7="http://namespace.ws"
> xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> <amember1 href="#id15"/>
> <cmember1 href="#id16"/>
> <cmember2 href="#id17"/>
> </multiRef>
> <multiRef id="id15" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="xsd:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> This is value of amember1
> </multiRef>
> <multiRef id="id16" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="xsd:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> This is value of cmember1
> </multiRef>
> <multiRef id="id17" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="xsd:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> This is value of cmember2
> </multiRef>
> For the same on 1.2 there is an issue
> ------------ Axis 1.2 beta Multiref section ---------------------
> <multiRef id="id7" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
> xsi:type="ns7:ContainerClass"
> xmlns:ns7="http://namespace.ws"
> xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> <aInstance href="#id14"/>
> </multiRef>
> <multiRef id="id14" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
> xsi:type="ns7:A" /// THIS IS DIFFERENT!!! This should be "ns7:C"
> xmlns:ns7="http://namespace.ws"
> xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> <amember1 href="#id15"/>
> <cmember1 href="#id16"/>
> <cmember2 href="#id17"/>
> </multiRef>
> <multiRef id="id15" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="xsd:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> This is value of amember1
> </multiRef>
> <multiRef id="id16" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="xsd:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> This is value of cmember1
> </multiRef>
> <multiRef id="id17" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="xsd:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
> This is value of cmember2
> </multiRef>
> In essence the super class type is being sent across with sub-class member data and that breaks
> the client which instantiates a super class object and tries calling 'set' methods on sub-class members
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://nagoya.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira