axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adam Kropp (JIRA)" <axis-...@ws.apache.org>
Subject [jira] Created: (AXIS-1715) ArraySerializer generates duplicate xsi:type attributes
Date Fri, 10 Dec 2004 23:28:09 GMT
ArraySerializer generates duplicate xsi:type attributes
-------------------------------------------------------

         Key: AXIS-1715
         URL: http://nagoya.apache.org/jira/browse/AXIS-1715
     Project: Axis
        Type: Bug
  Components: Serialization/Deserialization  
    Versions: 1.2RC2    
 Environment: Axis hosted in Tomcat, SOAP::Lite Perl client
    Reporter: Adam Kropp
    Priority: Minor


When serializing a complex type using the BeanSerializer and ArraySerializer classes, array
elements were getting generated with duplicate xsi:type attributes.  This causes XML validators
(i.e. in SOAP::Lite) to complain about invalid XML.

I tracked it down to a call to SerializationContext.setTypeAttribute(Attributes, QName). 
In this method, it checks whether the xsi:type attribute is already present using Constants.URI_DEFAULT_SCHEMA_XSI
(which is "http://www.w3.org/2001/XMLSchema-instance").  Unfortunately, in this case, the
actual XSI schema is "http://www.w3.org/1999/XMLSchema-instance"; thus the check fails and
it adds an additional xsi:type attribute to the attributes collection.

I was able to remedy this problem in my local build by replacing Constants.URI_DEFAULT_SCHEMA_XSI
with schemaVersion.getXsiURI().

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


Mime
View raw message