WebService returning invalide dateTime format

RESOLVED WORKSFORME

Status

()

Bugzilla
WebService
RESOLVED WORKSFORME
4 years ago
4 years ago

People

(Reporter: Frank Becker, Unassigned)

Tracking

Details

(Reporter)

Description

4 years ago
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_4) AppleWebKit/536.30.1 (KHTML, like Gecko) Version/6.0.5 Safari/536.30.1

Steps to reproduce:

1) use the new REST API with .../bugzilla-trunk/rest.cgi/bug?id=1&username=XXX&password=YYY
look for the field creation_time.


Actual results:

In my case I get  "2013-08-08T19:12:00Z".


Expected results:

I think the correct value should be  "2013-08-08T19:12:00-0000".

Comment 1

4 years ago
Per http://msdn.microsoft.com/en-us/library/windowsazure/dd894027.aspx, this is the correct format.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → WORKSFORME
(Reporter)

Comment 2

4 years ago
But per http://docs.oracle.com/javase/7/docs/api/java/text/SimpleDateFormat.html#rfc822timezone there is now way to get this parsed correctly when not in the UTC timezone.

You must code simpleFormatter.parse(replace("Z", " UTC")) to get the correct value. If we have 

"2013-08-08T19:12:00 UTC" or "2013-08-08T19:12:00 +0000" we can pass the string without the replace
You need to log in before you can comment on or make changes to this bug.