Package hudson.plugins.performance
Class PerformancePublisher
java.lang.Object
hudson.tasks.BuildStepCompatibilityLayer
hudson.tasks.Publisher
hudson.tasks.Recorder
hudson.plugins.performance.PerformancePublisher
- All Implemented Interfaces:
ExtensionPoint
,Describable<Publisher>
,BuildStep
,SimpleBuildStep
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class hudson.tasks.Publisher
Publisher.DescriptorExtensionListImpl
Nested classes/interfaces inherited from interface hudson.tasks.BuildStep
BuildStep.PublisherList
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
Nested classes/interfaces inherited from interface jenkins.tasks.SimpleBuildStep
SimpleBuildStep.LastBuildAction, SimpleBuildStep.LastBuildActionFactory
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
static final String
static final String
static final double
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
-
Constructor Summary
ConstructorsConstructorDescriptionPerformancePublisher
(String sourceDataFiles) PerformancePublisher
(String sourceDataFiles, int errorFailedThreshold, int errorUnstableThreshold, String errorUnstableResponseTimeThreshold, double relativeFailedThresholdPositive, double relativeFailedThresholdNegative, double relativeUnstableThresholdPositive, double relativeUnstableThresholdNegative, int nthBuildNumber, boolean modePerformancePerTestCase, String configType, boolean modeOfThreshold, boolean failBuildIfNoResultFile, boolean compareBuildPrevious, boolean modeThroughput, boolean showTrendGraphs, List<PerformanceReportParser> parsers) Legacy constructor used for internal references. -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Mapping classes after refactoring for backward compatibility.void
compareWithAbsoluteThreshold
(Run<?, ?> run, TaskListener listener, Collection<PerformanceReport> parsedReports) void
compareWithRelativeThreshold
(Run<?, ?> run, FilePath workspace, TaskListener listener, List<PerformanceReportParser> parsers) void
evaluateInExpertMode
(Run<?, ?> run, FilePath workspace, TaskListener listener) void
evaluateInStandardMode
(Run<?, ?> run, FilePath workspace, Collection<PerformanceReport> parsedReports, TaskListener listener, List<PerformanceReportParser> parsers) int
getBuildUriReports
(Run<?, ?> build, FilePath workspace, TaskListener listener, List<PerformanceReportParser> parsers, boolean locatePerformanceReports) boolean
List<? extends AbstractConstraint>
int
int
boolean
Run<?,
?> getnthBuild
(Run<?, ?> build) Gets the Build object entered in the text box "Compare with nth Build"int
protected List<PerformanceReportParser>
getParsers
(Run<?, ?> build, FilePath workspace, PrintStream logger, EnvVars env) static File
getPerformanceReport
(Run<?, ?> build, String parserDisplayName, String performanceReportName) static String
getPerformanceReportBuildFileName
(String performanceReportWorkspaceName) Delete the date suffix appended to the Performance result files by the Maven Performance pluginstatic File[]
getPerformanceReportDirectory
(Run<?, ?> build, String parserDisplayName, PrintStream logger) getProjectAction
(AbstractProject<?, ?> project) double
double
double
double
boolean
boolean
isART()
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
isMRT()
boolean
boolean
isPRT()
boolean
locatePerformanceReports
(FilePath workspace, String includes) look for performance reports based in the configured parameter includes.void
perform
(Run<?, ?> run, FilePath workspace, Launcher launcher, TaskListener listener) prepareEvaluation
(Run<?, ?> run, FilePath workspace, TaskListener listener, List<PerformanceReportParser> parsers) preparing evaluation - this is necessary regardless of the mode of evaluationThis method, invoked after object is resurrected from persistencevoid
setBaselineBuild
(int baselineBuild) void
setCompareBuildPrevious
(boolean compareBuildPrevious) void
setConfigType
(String configType) void
setConstraints
(List<? extends AbstractConstraint> constraints) void
setErrorFailedThreshold
(int errorFailedThreshold) void
setErrorUnstableResponseTimeThreshold
(String errorUnstableResponseTimeThreshold) void
setErrorUnstableThreshold
(int errorUnstableThreshold) void
setExcludeResponseTime
(boolean excludeResponseTime) void
setFailBuildIfNoResultFile
(boolean failBuildIfNoResultFile) void
setFilename
(String filename) void
setFilterRegex
(String filterRegex) void
setGraphType
(String graphType) void
setIgnoreFailedBuilds
(boolean ignoreFailedBuilds) void
setIgnoreUnstableBuilds
(boolean ignoreUnstableBuilds) void
setJunitOutput
(String junitOutput) void
setModeEvaluation
(boolean modeEvaluation) void
setModeOfThreshold
(boolean modeOfThreshold) void
setModePerformancePerTestCase
(boolean modePerformancePerTestCase) void
setModeThroughput
(boolean modeThroughput) void
setNthBuildNumber
(int nthBuildNumber) void
setParsers
(List<PerformanceReportParser> parsers) void
setPercentiles
(String percentiles) void
setPersistConstraintLog
(boolean persistConstraintLog) void
setRelativeFailedThresholdNegative
(double relativeFailedThresholdNegative) void
setRelativeFailedThresholdPositive
(double relativeFailedThresholdPositive) void
setRelativeUnstableThresholdNegative
(double relativeUnstableThresholdNegative) void
setRelativeUnstableThresholdPositive
(double relativeUnstableThresholdPositive) void
setShowTrendGraphs
(boolean showTrendGraphs) void
setSourceDataFiles
(String sourceDataFiles) Methods inherited from class hudson.tasks.Recorder
getDescriptor
Methods inherited from class hudson.tasks.Publisher
all, getProjectAction, needsToRunAfterFinalized, prebuild
Methods inherited from class hudson.tasks.BuildStepCompatibilityLayer
getProjectActions, perform, perform, prebuild
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface hudson.tasks.BuildStep
getProjectActions, perform, prebuild
Methods inherited from interface jenkins.tasks.SimpleBuildStep
perform, perform, requiresWorkspace
-
Field Details
-
THRESHOLD_TOLERANCE
public static final double THRESHOLD_TOLERANCE- See Also:
-
ART
- See Also:
-
MRT
- See Also:
-
PRT
- See Also:
-
optionType
-
-
Constructor Details
-
PerformancePublisher
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class) public PerformancePublisher(String sourceDataFiles, int errorFailedThreshold, int errorUnstableThreshold, String errorUnstableResponseTimeThreshold, double relativeFailedThresholdPositive, double relativeFailedThresholdNegative, double relativeUnstableThresholdPositive, double relativeUnstableThresholdNegative, int nthBuildNumber, boolean modePerformancePerTestCase, String configType, boolean modeOfThreshold, boolean failBuildIfNoResultFile, boolean compareBuildPrevious, boolean modeThroughput, boolean showTrendGraphs, List<PerformanceReportParser> parsers) Legacy constructor used for internal references. -
PerformancePublisher
-
-
Method Details
-
getPerformanceReport
-
getProjectAction
- Specified by:
getProjectAction
in interfaceBuildStep
- Overrides:
getProjectAction
in classBuildStepCompatibilityLayer
-
getRequiredMonitorService
- Specified by:
getRequiredMonitorService
in interfaceBuildStep
-
getPerformanceReportBuildFileName
Delete the date suffix appended to the Performance result files by the Maven Performance plugin
- Returns:
- the name of the PerformanceReport in the Build
-
locatePerformanceReports
protected static List<FilePath> locatePerformanceReports(FilePath workspace, String includes) throws IOException, InterruptedException look for performance reports based in the configured parameter includes. 'includes' is - an Ant-style pattern - a list of files and folders separated by the characters ;:,- Throws:
IOException
InterruptedException
-
getParsers
protected List<PerformanceReportParser> getParsers(Run<?, ?> build, FilePath workspace, PrintStream logger, EnvVars env) throws IOException, InterruptedException- Throws:
IOException
InterruptedException
-
readResolve
This method, invoked after object is resurrected from persistence -
perform
public void perform(@NonNull Run<?, ?> run, @NonNull FilePath workspace, @NonNull Launcher launcher, @NonNull TaskListener listener) throws InterruptedException, IOException- Specified by:
perform
in interfaceSimpleBuildStep
- Throws:
InterruptedException
IOException
-
prepareEvaluation
public Collection<PerformanceReport> prepareEvaluation(Run<?, ?> run, FilePath workspace, TaskListener listener, List<PerformanceReportParser> parsers) throws IOException, InterruptedExceptionpreparing evaluation - this is necessary regardless of the mode of evaluation- Throws:
IOException
InterruptedException
-
getBuildUriReports
protected List<UriReport> getBuildUriReports(Run<?, ?> build, FilePath workspace, TaskListener listener, List<PerformanceReportParser> parsers, boolean locatePerformanceReports) throws IOException, InterruptedException- Throws:
IOException
InterruptedException
-
evaluateInStandardMode
public void evaluateInStandardMode(Run<?, ?> run, FilePath workspace, Collection<PerformanceReport> parsedReports, TaskListener listener, List<PerformanceReportParser> parsers) throws IOException, InterruptedException- Throws:
IOException
InterruptedException
-
compareWithAbsoluteThreshold
public void compareWithAbsoluteThreshold(Run<?, ?> run, TaskListener listener, Collection<PerformanceReport> parsedReports) -
compareWithRelativeThreshold
public void compareWithRelativeThreshold(Run<?, ?> run, FilePath workspace, TaskListener listener, List<PerformanceReportParser> parsers) throws IOException, InterruptedException- Throws:
IOException
InterruptedException
-
evaluateInExpertMode
public void evaluateInExpertMode(Run<?, ?> run, FilePath workspace, TaskListener listener) throws IOException, InterruptedException- Throws:
IOException
InterruptedException
-
getErrorFailedThreshold
public int getErrorFailedThreshold() -
setErrorFailedThreshold
@DataBoundSetter public void setErrorFailedThreshold(int errorFailedThreshold) -
getErrorUnstableThreshold
public int getErrorUnstableThreshold() -
setErrorUnstableThreshold
@DataBoundSetter public void setErrorUnstableThreshold(int errorUnstableThreshold) -
getErrorUnstableResponseTimeThreshold
-
setErrorUnstableResponseTimeThreshold
@DataBoundSetter public void setErrorUnstableResponseTimeThreshold(String errorUnstableResponseTimeThreshold) -
isModePerformancePerTestCase
public boolean isModePerformancePerTestCase() -
setModePerformancePerTestCase
@DataBoundSetter public void setModePerformancePerTestCase(boolean modePerformancePerTestCase) -
getFilename
-
setFilename
-
isFailBuildIfNoResultFile
public boolean isFailBuildIfNoResultFile() -
setFailBuildIfNoResultFile
@DataBoundSetter public void setFailBuildIfNoResultFile(boolean failBuildIfNoResultFile) -
isART
public boolean isART() -
isMRT
public boolean isMRT() -
isPRT
public boolean isPRT() -
getPerformanceReportDirectory
public static File[] getPerformanceReportDirectory(Run<?, ?> build, String parserDisplayName, PrintStream logger) -
getnthBuild
Gets the Build object entered in the text box "Compare with nth Build"- Parameters:
build
- , listener- Returns:
- build object
-
getRelativeFailedThresholdPositive
public double getRelativeFailedThresholdPositive() -
getRelativeFailedThresholdNegative
public double getRelativeFailedThresholdNegative() -
setRelativeFailedThresholdPositive
@DataBoundSetter public void setRelativeFailedThresholdPositive(double relativeFailedThresholdPositive) -
setRelativeFailedThresholdNegative
@DataBoundSetter public void setRelativeFailedThresholdNegative(double relativeFailedThresholdNegative) -
getRelativeUnstableThresholdPositive
public double getRelativeUnstableThresholdPositive() -
getRelativeUnstableThresholdNegative
public double getRelativeUnstableThresholdNegative() -
setRelativeUnstableThresholdPositive
@DataBoundSetter public void setRelativeUnstableThresholdPositive(double relativeUnstableThresholdPositive) -
setRelativeUnstableThresholdNegative
@DataBoundSetter public void setRelativeUnstableThresholdNegative(double relativeUnstableThresholdNegative) -
getNthBuildNumber
public int getNthBuildNumber() -
setNthBuildNumber
@DataBoundSetter public void setNthBuildNumber(int nthBuildNumber) -
getConfigType
-
setConfigType
-
getGraphType
-
setGraphType
-
getModeOfThreshold
public boolean getModeOfThreshold() -
setModeOfThreshold
@DataBoundSetter public void setModeOfThreshold(boolean modeOfThreshold) -
getCompareBuildPrevious
public boolean getCompareBuildPrevious() -
setCompareBuildPrevious
@DataBoundSetter public void setCompareBuildPrevious(boolean compareBuildPrevious) -
isModeThroughput
public boolean isModeThroughput() -
setModeThroughput
@DataBoundSetter public void setModeThroughput(boolean modeThroughput) -
getConstraints
-
setConstraints
-
setIgnoreFailedBuilds
@DataBoundSetter public void setIgnoreFailedBuilds(boolean ignoreFailedBuilds) -
isIgnoreFailedBuilds
public boolean isIgnoreFailedBuilds() -
setIgnoreUnstableBuilds
@DataBoundSetter public void setIgnoreUnstableBuilds(boolean ignoreUnstableBuilds) -
isIgnoreUnstableBuilds
public boolean isIgnoreUnstableBuilds() -
isPersistConstraintLog
public boolean isPersistConstraintLog() -
setPersistConstraintLog
@DataBoundSetter public void setPersistConstraintLog(boolean persistConstraintLog) -
isModeEvaluation
public boolean isModeEvaluation() -
setModeEvaluation
@DataBoundSetter public void setModeEvaluation(boolean modeEvaluation) -
setShowTrendGraphs
@DataBoundSetter public void setShowTrendGraphs(boolean showTrendGraphs) -
isShowTrendGraphs
public boolean isShowTrendGraphs() -
getShowTrendGraphs
public boolean getShowTrendGraphs() -
getSourceDataFiles
-
setSourceDataFiles
-
getParsers
-
setParsers
-
isExcludeResponseTime
public boolean isExcludeResponseTime() -
setExcludeResponseTime
@DataBoundSetter public void setExcludeResponseTime(boolean excludeResponseTime) -
getJunitOutput
-
setJunitOutput
-
getPercentiles
-
setPercentiles
-
getBaselineBuild
public int getBaselineBuild() -
setBaselineBuild
@DataBoundSetter public void setBaselineBuild(int baselineBuild) -
addAliases
Mapping classes after refactoring for backward compatibility. -
getFilterRegex
- Returns:
- the filterRegex
-
setFilterRegex
- Parameters:
filterRegex
- the filterRegex to set
-