This plugin allows you to distinguish good builds from bad builds by introducing the notion of 'promotion'. Put simply, a promoted build is a successful build that passed additional criteria (such as more comprehensive tests that are set up as downstream jobs.) The typical situation in which you use promotion is where you have multiple 'test' jobs hooked up as downstream jobs of a 'build' job. You'll then configure the build job so that the build gets promoted when all the test jobs passed successfully. This allows you to keep the build job run fast (so that developers get faster feedback when a build fails), and you can still distinguish builds that are good from builds that compiled but had runtime problems.
Another variation of this usage is to manually promote builds (based on instinct or something else that runs outside Hudson.) Promoted builds will get a star in the build history view, and it can be then picked up by other teams, deployed to the staging area, etc., as those builds have passed additional quality criteria. In more complicated scenarios, one can set up multiple levels of promotions. This fits nicely in an environment where there are multiple stages of testings (for example, QA testing, acceptance testing, staging, and production.)
When a build is promoted, you can have Hudson perform some actions (such as running a shell script, triggering other jobs, etc. — or in Hudson lingo, you can run build steps.) This is useful for example to copy the promoted build to somewhere else, deploy it to your QA server. You can also define it as a separate job and then have the promotion action trigger that job.
|Do not rely on files in the workspace|
The promotion action uses the workspace of the job as the current directory (and as such the execution of the promotion action is mutually exclusive from any on-going builds of the job.) But by the time promotion runs, this workspace can contain files from builds that are totally unrelated from the build being promoted.
To access the artifacts, use the Copy Artifact Plugin and choose the permalink.
TODO: talk about a typical set up, the configuration, manual promotion, PROMOTED_URL.
Version 1.11 (Jan 31 2011)
- Promote a build even if downstream build is unstable. (issue #8626)
- Promote Builds Plugin can use custom workspace. (issue #8547)
- Invalid characters in Promotion name causes error. (issue #7972)
- Fix promotion permlinks. (issue #8367)
- Allow promotion actions to be reordered. (issue #8548)
Version 1.10 (Sep 28 2010)
- Promotion processes are now recognized as permalinks.
Version 1.9 (Jun 9 2010)
- If fingerprints are not available, use the upstream/downstream triggering information to determine the relationship as a fallback.
Version 1.8 (Jun 5 2010)
- Add the possibility to choose a different color for the star icon, to be able to differenciate the various promotion processes
Version 1.7 (Mar 29 2010)
- Use JDK configured for project when running promotions (issue #3526)
- Select node for running promotions from label configured for project (issue #4089) (does not yet run on exact node where promoted build ran, unless project is tied to a single node)
- Show most-recent first in promotion history tables (issue #6073)
Version 1.6 (Dec 30 2009)
Version 1.5 (Aug 17 2009)
- Updated to work with Hudson 1.320
Version 1.4 (May 21 2009)
- Re-doing a release as 1.3 had never shown up in the update center.
Version 1.3 (May 11 2009)
- Expose environment variable 'PROMOTED_URL' that points to the URL of the build that's being promoted (report)
- Internal modernization.
Version 1.2 (Mar 25 2009)
- Updated to work with the current Hudson
Version 1.1 (Feb 20 2009)
- Fixed a problem where Hudson may issue the same warning multiple times for the same configuration problem (report)
- SVN Tagging is now a permitted promotion step
- Promotion now fails if any actions are not performed (issue #2597)
- Improved logging of promotion build process so users can see what succeeded and what failed
- Promotion action to build another project no longer does nothing (issue #1765)
- Added "Promotion History" pane to the PromotedBuildAction page (issue #2794)
- Fixed 404 for last failed link while promotion build occuring (issue #2578)