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

buildWithParameters doesn't redirect to the build page

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • core
    • None

      In version 1.561, POST request for /buildWithParameters doesn't redirect to the build page like it did until 1.560.

          [JENKINS-22865] buildWithParameters doesn't redirect to the build page

          Orgad Shaneh created issue -
          Daniel Beck made changes -
          Link New: This issue is related to JENKINS-13546 [ JENKINS-13546 ]

          Daniel Beck added a comment -

          There was a deliberate change to the behavior of buildWithParameters in Jenkins 1.561, see linked issue and changelog.

          What exactly is the problem here? Could you provide steps to reproduce the issue, what the expected result should be, and what the actual result is? Right now, it's unclear whether this is due to the deliberate change or some unexpected side effect you're reporting.

          Daniel Beck added a comment - There was a deliberate change to the behavior of buildWithParameters in Jenkins 1.561, see linked issue and changelog. What exactly is the problem here? Could you provide steps to reproduce the issue, what the expected result should be, and what the actual result is? Right now, it's unclear whether this is due to the deliberate change or some unexpected side effect you're reporting.

          Daniel Beck added a comment -

          No response to comment asking for clarification in half a year, so resolving as Incomplete.

          Daniel Beck added a comment - No response to comment asking for clarification in half a year, so resolving as Incomplete.
          Daniel Beck made changes -
          Resolution New: Incomplete [ 4 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]

          Orgad Shaneh added a comment -

          Sorry for the late response. I didn't notice the previous comment.

          In my use-case, I have a web form with action=.../buildWithParameters target=_blank and method=post. I expect that when the form is submitted and the new tab is opened, that it won't be blank, but will be redirected to either the newly created job or if that's not possible (because the job hasn't started yet) to the project page.

          Orgad Shaneh added a comment - Sorry for the late response. I didn't notice the previous comment. In my use-case, I have a web form with action=.../buildWithParameters target=_blank and method=post. I expect that when the form is submitted and the new tab is opened, that it won't be blank, but will be redirected to either the newly created job or if that's not possible (because the job hasn't started yet) to the project page.
          Orgad Shaneh made changes -
          Resolution Original: Incomplete [ 4 ]
          Status Original: Resolved [ 5 ] New: Reopened [ 4 ]

          Daniel Beck added a comment -

          /buildWithParameters is the programmatic API endpoint. It sends a Location header value specifying the location of the queue item with information about the queued job. So the behavior you're seeing is intentional.

          You may be able to make /build work.

          Daniel Beck added a comment - /buildWithParameters is the programmatic API endpoint. It sends a Location header value specifying the location of the queue item with information about the queued job. So the behavior you're seeing is intentional. You may be able to make /build work.
          Daniel Beck made changes -
          Resolution New: Won't Fix [ 2 ]
          Status Original: Reopened [ 4 ] New: Resolved [ 5 ]

          Gavin Shelley added a comment -

          2 things to mention here :-

          1) I'm sure the /buildWithParameters used to work and successfully redirected to the job page, so useful behaviour was lost (I get asked for it back every week or so)

          2) The patch in the linked issue seems to try and include a redirect, so is it trying to do what this issue asks for and failing, or am I reading it wrong?

          Gavin Shelley added a comment - 2 things to mention here :- 1) I'm sure the /buildWithParameters used to work and successfully redirected to the job page, so useful behaviour was lost (I get asked for it back every week or so) 2) The patch in the linked issue seems to try and include a redirect, so is it trying to do what this issue asks for and failing, or am I reading it wrong?

            Unassigned Unassigned
            orgads Orgad Shaneh
            Votes:
            3 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated: