Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-22849

Send 201 (Created) response with a Location header pointing to the queue item once job submitted

      Instead of simply returning "Scheduled" once a job has been launched, it would be nice that the job ID/number would be returned so that it can be reused in the API for further tracking.

          [JENKINS-22849] Send 201 (Created) response with a Location header pointing to the queue item once job submitted

          Code changed in jenkins
          User: Jesse Glick
          Path:
          src/main/java/org/jenkinsci/plugins/build_token_root/BuildRootAction.java
          src/test/java/org/jenkinsci/plugins/build_token_root/BuildRootActionTest.java
          http://jenkins-ci.org/commit/build-token-root-plugin/e7257ce102c2933566dab1a8ee0b2dfeda2313fc
          Log:
          Merge pull request #8 from ydubreuil/jenkins-29615

          JENKINS-22849 Improve HTTP response to include item queue location

          Compare: https://github.com/jenkinsci/build-token-root-plugin/compare/f1239a38e9e9...e7257ce102c2

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: src/main/java/org/jenkinsci/plugins/build_token_root/BuildRootAction.java src/test/java/org/jenkinsci/plugins/build_token_root/BuildRootActionTest.java http://jenkins-ci.org/commit/build-token-root-plugin/e7257ce102c2933566dab1a8ee0b2dfeda2313fc Log: Merge pull request #8 from ydubreuil/jenkins-29615 JENKINS-22849 Improve HTTP response to include item queue location Compare: https://github.com/jenkinsci/build-token-root-plugin/compare/f1239a38e9e9...e7257ce102c2

          Wouldn't it be better to return url to scheduled job instead ? Http call to get details about queue item requires authentication  (queueItem url + "api/json") and it doesn't accept token which was used for triggering build. Queue item url is not that useful here. Am I missing something ?

          Kamill Wójcik added a comment - Wouldn't it be better to return url to scheduled job instead ? Http call to get details about queue item requires authentication  (queueItem url + "api/json") and it doesn't accept token which was used for triggering build. Queue item url is not that useful here. Am I missing something ?

            ydubreuil Yoann Dubreuil
            fournierd Dan Fournier
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: