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

Pipeline Model Definition Post Action Order

XMLWordPrintable

      The post.always action should be the last action run in a stage or pipeline. At present it will run BEFORE the post.success, aborted, and failure actions which doesn't make much sense.

      Example:

      I want to clean the workspace at the end of a stage regardless of status, and I want to archive some files on success. The logical way to achieve this is to clean the workspace in the post.always and archive the files on post.success. This is not possible in the current plugin.

       

      I know there are ways to get round this 'feature' but they are not exactly intuitive.

      Attached a simple pipeline to demonstrate the issue.

       

            abayer Andrew Bayer
            rayalexander Ray Alexander
            Votes:
            2 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: