axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Detelin Yordanov (JIRA)" <j...@apache.org>
Subject [jira] Updated: (AXIS2-3974) BeanUtil.deserialize does not handle xsi:nil attribute properly
Date Mon, 18 Aug 2008 16:00:46 GMT

     [ https://issues.apache.org/jira/browse/AXIS2-3974?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Detelin Yordanov updated AXIS2-3974:
------------------------------------

    Attachment: HTTP_log.txt

The http request and response.

> BeanUtil.deserialize does not handle xsi:nil attribute properly
> ---------------------------------------------------------------
>
>                 Key: AXIS2-3974
>                 URL: https://issues.apache.org/jira/browse/AXIS2-3974
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: adb
>    Affects Versions: nightly
>         Environment: Axis2 Trunk with experimental multidimensional array support (thanks
to Amila)
>            Reporter: Detelin Yordanov
>         Attachments: BeanUtil_patch.txt, HTTP_log.txt, NullArrayTest.zip
>
>
> The BeanUtil.deserialize(Class, OMElement, ObjectSupplier, String) in Adb module does
not handle xsi:nil attributes on array elements properly.
> In the given example test case a 2D string array (that is part of a POJO) is being sent
to an Echo Java service.
> The 2D array contains an null array and a null array element:
> String[][] stringArray2D = new String[][] { new String[] { "axis2", null}, null}
> The request is send using ADB client stub and it's OK:
> <ns2:echoSimplePOJO xmlns:ns2="http://test.tempuri.org">
>     <ns2:simplePOJO>
>          <names xmlns="http://test.tempuri.org/xsd">
>              <names>axis2</names>
>              <names xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:nil="1"
/>
>           </names>
>           <ns1:names xmlns:ns1="http://test.tempuri.org/xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:nil="1" />
> </ns2:simplePOJO>
> The request, however, contains an empty string rather than a null string, and does not
contain the null array:
> <ns:return xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ax23="http://test.tempuri.org/xsd"
xsi:type="ax23:SimplePOJO">
>     <ax23:names>
>          <ax23:names>axis2</ax23:names>
>          <ax23:names></ax23:names>
>     </ax23:names>
> </ns:return>
> The problem is that the deserialize(..) method does not check for xsi:nil.
> Additionally it does not put deserialized null array elements inside the valueList, so
they are effectively skipped.

-- 
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


Mime
View raw message