Description
There is a problem in Date type parameter processing. Just deploy a pojo with the following method:
public Date testDate(Date date) {
return date;
}
and then invoke the ws with the following request:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:q0="http://test" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<q0:testDate>
<q0:date>2009-11-18</q0:date>
</q0:testDate>
</soapenv:Body>
</soapenv:Envelope>
and you get an error.
In order to fix this problem, you have to change the line 313 in class org.apache.axis2.databinding.typemapping.SimpleTypeMapper from
return ConverterUtil.convertToDateTime(source).getTime();
to
return ConverterUtil.convertToDate(source);
Attachments
Issue Links
- is duplicated by
-
AXIS2-4626 Wrong Date handling in SimpleTypeMapper
- Closed