-
Bug
-
Resolution: Fixed
-
Major
-
Version 1.460 on both OS X 10.7 and 10.5, as well as http://ci.jenkins-ci.org/
When making requests to the JSON API, responses are specifying a content type of application/javascript instead of application/json as defined in RFC4627
The following is the response form http://ci.jenkins-ci.org/view/Jenkins core/api/json
HTTP/1.1 200 OK
Content-Length: 640
Server: Winstone Servlet Engine v0.9.10
Content-Type: application/javascript;charset=UTF-8
Connection: Close
Date: Sat, 21 Apr 2012 03:55:50 GMT
X-Powered-By: Servlet/2.5 (Winstone/0.9.10)
Set-Cookie: SERVERID=Local; path=/
Cache-Control: private
- depends on
-
JENKINS-16069 Combobox component broken since 1.480
-
- Resolved
-
Jenkins sets content type based on the requested export format. Whenever json format is requested, we use Flavor enumeration from Stapler framework to set response content type.
https://github.com/stapler/stapler/blob/master/core/src/main/java/org/kohsuke/stapler/export/Flavor.java
Currently for JSON flavor it has "application/javascript" content type.