Quantcast

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
Justin Mutter created JENKINS-13541:
---------------------------------------

             Summary: Content Type of JSON API responses is not 'application/json'
                 Key: JENKINS-13541
                 URL: https://issues.jenkins-ci.org/browse/JENKINS-13541
             Project: Jenkins
          Issue Type: Bug
          Components: core
         Environment: Version 1.460 on both OS X 10.7 and 10.5, as well as http://ci.jenkins-ci.org/
            Reporter: Justin Mutter


When making requests to the JSON API, responses are specifying a content type of *application/javascript* instead of *application/json* as defined in [RFC4627|http://www.ietf.org/rfc/rfc4627.txt]

The following is the response form http://ci.jenkins-ci.org/view/Jenkins core/api/json

{code}
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
{code}



--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jenkins-ci.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org

    [ https://issues.jenkins-ci.org/browse/JENKINS-13541?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=163428#comment-163428 ]

Andrey Myatlyuk commented on JENKINS-13541:
-------------------------------------------

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.
               

> Content Type of JSON API responses is not 'application/json'
> ------------------------------------------------------------
>
>                 Key: JENKINS-13541
>                 URL: https://issues.jenkins-ci.org/browse/JENKINS-13541
>             Project: Jenkins
>          Issue Type: Bug
>          Components: core
>         Environment: Version 1.460 on both OS X 10.7 and 10.5, as well as http://ci.jenkins-ci.org/
>            Reporter: Justin Mutter
>              Labels: api, json
>
> When making requests to the JSON API, responses are specifying a content type of *application/javascript* instead of *application/json* as defined in [RFC4627|http://www.ietf.org/rfc/rfc4627.txt]
> The following is the response form http://ci.jenkins-ci.org/view/Jenkins core/api/json
> {code}
> 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
> {code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jenkins-ci.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
In reply to this post by JIRA noreply@jenkins-ci.org

    [ https://issues.jenkins-ci.org/browse/JENKINS-13541?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=163429#comment-163429 ]

Andrey Myatlyuk commented on JENKINS-13541:
-------------------------------------------

Submitted request on Stapler project, once I get green light on that, that issue with Jenkins will be consequently resolved.

http://java.net/jira/browse/STAPLER-17
               

> Content Type of JSON API responses is not 'application/json'
> ------------------------------------------------------------
>
>                 Key: JENKINS-13541
>                 URL: https://issues.jenkins-ci.org/browse/JENKINS-13541
>             Project: Jenkins
>          Issue Type: Bug
>          Components: core
>         Environment: Version 1.460 on both OS X 10.7 and 10.5, as well as http://ci.jenkins-ci.org/
>            Reporter: Justin Mutter
>              Labels: api, json
>
> When making requests to the JSON API, responses are specifying a content type of *application/javascript* instead of *application/json* as defined in [RFC4627|http://www.ietf.org/rfc/rfc4627.txt]
> The following is the response form http://ci.jenkins-ci.org/view/Jenkins core/api/json
> {code}
> 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
> {code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jenkins-ci.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
In reply to this post by JIRA noreply@jenkins-ci.org

     [ https://issues.jenkins-ci.org/browse/JENKINS-13541?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrey Myatlyuk reassigned JENKINS-13541:
-----------------------------------------

    Assignee: Andrey Myatlyuk
   

> Content Type of JSON API responses is not 'application/json'
> ------------------------------------------------------------
>
>                 Key: JENKINS-13541
>                 URL: https://issues.jenkins-ci.org/browse/JENKINS-13541
>             Project: Jenkins
>          Issue Type: Bug
>          Components: core
>         Environment: Version 1.460 on both OS X 10.7 and 10.5, as well as http://ci.jenkins-ci.org/
>            Reporter: Justin Mutter
>            Assignee: Andrey Myatlyuk
>              Labels: api, json
>
> When making requests to the JSON API, responses are specifying a content type of *application/javascript* instead of *application/json* as defined in [RFC4627|http://www.ietf.org/rfc/rfc4627.txt]
> The following is the response form http://ci.jenkins-ci.org/view/Jenkins core/api/json
> {code}
> 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
> {code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jenkins-ci.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
In reply to this post by JIRA noreply@jenkins-ci.org
Andrey Myatlyuk resolved Bug JENKINS-13541 as Fixed

Fixed in version 1.471

{{
Connection Keep-Alive
Content-Encoding gzip
Content-Length 313
Content-Type application/json;charset=UTF-8
Date Thu, 14 Jun 2012 19:39:10 GMT
Server Winstone Servlet Engine v0.9.10
X-Powered-By Servlet/2.5 (Winstone/0.9.10)
}}

Please verify.

Change By: Andrey Myatlyuk (14/Jun/12 7:49 PM)
Status: Open Resolved
Fix Version/s: current
Resolution: Fixed
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
In reply to this post by JIRA noreply@jenkins-ci.org
 
Andrey Myatlyuk edited a comment on Bug JENKINS-13541

Fixed in version 1.471

Connection Keep-Alive
Content-Encoding gzip
Content-Length 313
Content-Type application/json;charset=UTF-8
Date Thu, 14 Jun 2012 19:39:10 GMT
Server Winstone Servlet Engine v0.9.10
X-Powered-By Servlet/2.5 (Winstone/0.9.10)

Please verify.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
In reply to this post by JIRA noreply@jenkins-ci.org
Justin Mutter closed Bug JENKINS-13541 as Fixed

Updated to 1.471 and confirmed correct JSON content type

Change By: Justin Mutter (20/Jun/12 7:38 PM)
Status: Resolved Closed
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
In reply to this post by JIRA noreply@jenkins-ci.org

Looks good, thanks!

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
In reply to this post by JIRA noreply@jenkins-ci.org

Code changed in jenkins
User: Jesse Glick
Path:
changelog.html
http://jenkins-ci.org/commit/jenkins/bb3be8314cc04c54838331da088d35e46b68a224
Log:
JENKINS-13541 Noting.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

[JIRA] (JENKINS-13541) Content Type of JSON API responses is not 'application/json'

JIRA noreply@jenkins-ci.org
In reply to this post by JIRA noreply@jenkins-ci.org
dogfood commented on Bug JENKINS-13541

Integrated in jenkins_main_trunk #2208
JENKINS-13541 Noting. (Revision bb3be8314cc04c54838331da088d35e46b68a224)

Result = SUCCESS
Jesse Glick : bb3be8314cc04c54838331da088d35e46b68a224
Files :

  • changelog.html
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
Loading...