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

Wrong revision built when using post-commit hook and a commit occur during quiet period

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: subversion-plugin
    • Labels:
      None
    • Environment:
      Windows Server 2008
      Hudson 1.388
      Subversion plugin 1.21
    • Similar Issues:

      Description

      This appears to be related to a change made in Subversion plugin 1.18:

      "Builds triggered via the post-commit hook check out from the revision specified by the hook. The hook specifies the revision with either the rev query parameter, or the X-Hudson-Subversion-Revision HTTP header."

      To reproduce:
      1) Set up SVN to use a post-commit hook as described on the Subversion plugin page
      2) Set up a Hudson job using subversion as its SCM and a quiet period (mine is 60 seconds)
      3) Commit a change and note the resulting revision number.
      4) Observe job is queued in hudson
      5) Commit another change before quiet period expires and note the revision number.
      6) Quiet period resets as expected
      7) Once quiet period expires the job will run, but it will checkout with the revision number from step 3 instead of 5

      This is a major problem because the commit in step (5) above are ignored by hudson. The build that is done does not incorporate the second changes, and a second build is not triggered. The behavior I would expect is that if the changes are committed before the quiet period is expired, then those changes should be included in the upcoming build.

      I haven't investigated fully, but it seems that the Hudson core code has a mechanism to do this with the FoldableAction interface. It might be possible to make the RevisionParameterAction implement this interface in order to update its state when a new commit notification is received.

        Attachments

          Activity

          kbell Kevin Bell created issue -
          kbell Kevin Bell made changes -
          Field Original Value New Value
          Assignee kbell [ kbell ]
          kbell Kevin Bell made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          kbell Kevin Bell made changes -
          Attachment JENKINS-8266.patch [ 20096 ]
          dty Dean Yu made changes -
          Status In Progress [ 3 ] Resolved [ 5 ]
          Assignee kbell [ kbell ] dty [ dty ]
          Resolution Fixed [ 1 ]
          rtyler R. Tyler Croy made changes -
          Workflow JNJira [ 138376 ] JNJira + In-Review [ 187975 ]

            People

            • Assignee:
              dty Dean Yu
              Reporter:
              kbell Kevin Bell
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: