public class FirstRecorder
extends hudson.tasks.Recorder
Recorder, which is a Publisher.
Publisher are BuildSteps performed in the post build phase. They are designed for reporting.
The build phase usually involves building or compiling, and maybe some rudimentary smoke test of your software.
Then in the post build phase you're more likely to perform static analysis of your source code, check for coverage and maybe compiler warnings.
Our example demonstrates in a very simple way how the post build step can be used to set the overall result of a given build.
Our example recorder requires the user to enter a string, that must be contained as a part build steps in order to be considered stable.| Modifier and Type | Class and Description |
|---|---|
static class |
FirstRecorder.DescriptorImpl
Required class with a concrete implementation of the descriptor.
|
hudson.tasks.Publisher.DescriptorExtensionListImpl| Constructor and Description |
|---|
FirstRecorder()
Required constructor.
|
| Modifier and Type | Method and Description |
|---|---|
hudson.model.Action |
getProjectAction(hudson.model.AbstractProject<?,?> project)
This method returns a project action you wish to have displayed on the front page
|
hudson.tasks.BuildStepMonitor |
getRequiredMonitorService() |
boolean |
perform(hudson.model.Build<?,?> build,
hudson.Launcher launcher,
hudson.model.BuildListener listener)
Performs the required operations for this build step.
|
all, getProjectAction, needsToRunAfterFinalized, prebuild@DataBoundConstructor public FirstRecorder()
public boolean perform(hudson.model.Build<?,?> build,
hudson.Launcher launcher,
hudson.model.BuildListener listener)
throws InterruptedException,
IOException
AbortException.
This very simple reference implementation contains code that checks if the action contains items with the text, you specify when configuring
the FirstRecorder project.perform in class hudson.tasks.BuildStepCompatibilityLayerbuild - launcher - listener - InterruptedExceptionIOExceptionpublic hudson.tasks.BuildStepMonitor getRequiredMonitorService()
public hudson.model.Action getProjectAction(hudson.model.AbstractProject<?,?> project)
getProjectAction in interface hudson.tasks.BuildStepgetProjectAction in class hudson.tasks.BuildStepCompatibilityLayerproject - Copyright © 2004-2016. All Rights Reserved.