Class SecuredFinishedBuildImpl
- java.lang.Object
-
- jetbrains.buildServer.serverSide.impl.BaseBuild
-
- jetbrains.buildServer.serverSide.impl.FinishedBuildImpl
-
- jetbrains.buildServer.serverSide.impl.auth.SecuredFinishedBuildImpl
-
- All Implemented Interfaces:
Build,BuildEx,BuildPromotionOwner,FinishedBuildEx,ParametersSupport,SBuild,SFinishedBuild
public class SecuredFinishedBuildImpl extends FinishedBuildImpl
Created 24.04.13 15:54
-
-
Field Summary
-
Fields inherited from class jetbrains.buildServer.serverSide.impl.BaseBuild
myBuildId, myContext, myStatsCallCounter, REMOTE_ARTIFACTS_PREFIX
-
-
Constructor Summary
Constructors Constructor Description SecuredFinishedBuildImpl(long buildId, long buildPromotionId, String buildTypeId, String agentName, int agentTypeId, Date buildStartTimeServer, Date buildStartTimeAgent, Date buildFinishTimeServer, Status buildStatus, String finalStatusText, String buildNumber, boolean pin, boolean personal, CanceledInfo canceledInfo, String requestor, String buildDescription, BuildPromotionEx buildPromotion, BuildContext context)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BuildProblemDataaddUserBuildProblem(SUser user, String problemDescription)Adds user provided build problem to the build.voiddeleteBuildProblem(SUser user, String identity, String comment)Deletes build problem Deleting build problem may change build status to SUCCESSBuildAgentExgetAgent()DepParametersMemoryOptimizedMapgetBuildFinishParameters()This method returns build parameters (env, config, system) that were on build agent at the end of this build.DepParametersMemoryOptimizedMapgetBuildStartParameters()This method returns build parameters (env, config, system) that were on build agent before build runners are called in the build.SortedMap<BuildTypeEx,BuildPromotionEx>getDeploymentStatus()voidmuteBuildProblems(SUser user, boolean muteIfTrue, String comment)Makes all existing build problems enabled or disabledvoidsetBuildComment(User user, String comment)Sets the comment for the buildvoidsetLabel(String labelValue, List<VcsRootInstance> rootsToLabel)Sets a label on files in VCS repository used by this build in the specified VCS rootsvoidsetPinned(boolean pinned, User user, String comment)Sets pin status for this build.voidsetTags(List<String> tags)Sets public tags for this buildvoidsetTags(User user, List<String> tags)Sets public tags for this buildvoidupdatePinInfo()Reload pin status from the database-
Methods inherited from class jetbrains.buildServer.serverSide.impl.FinishedBuildImpl
beforeDelete, buildEvictedFromCache, equals, getAgentName, getBuildCounter, getBuildDescription, getBuildLog, getBuildLogIfInitialized, getBuildNumber, getBuildPromotion, getBuildStatistics, getBuildStatus, getBuildType, getBuildTypeExternalId, getBuildTypeId, getCachedShortStatistics, getCanceledInfo, getFinishDate, getFinishOnAgentDate, getPinComment, getProjectExternalId, getProjectId, getRawBuildNumber, getStatusDescriptor, hashCode, isAgentLessBuild, isCompositeBuild, isDetachedFromAgent, isFinished, isPersonal, isPinned, notifyOnBuildProblemsChanged, resetFullStatisticsCache, resetShortStatisticsCache, setLabel, setPinned, setStatusText, toString, updateStatusText
-
Methods inherited from class jetbrains.buildServer.serverSide.impl.BaseBuild
addBuildProblem, buildProblemsChanged, convertToAgentTime, convertToServerTime, createShortStatistics, doGetBuildFinishParameters, doGetBuildStartParameters, getArtifactDependencies, getArtifacts, getArtifactsDirectory, getAuditLogFactory, getAuditLogProvider, getBranch, getBuildComment, getBuildContext, getBuildFeaturesOfType, getBuildId, getBuildNumberParameters, getBuildNumberWithoutRefs, getBuildOwnParameters, getBuildProblems, getBuildTypeName, getChanges, getClientStartDate, getClientTimeZone, getCommitters, getCompilationErrorMessages, getContainingChanges, getCustomDataStorage, getCustomDataStorageIdsByPrefix, getDetachFromAgentReceivedTimestamp, getDownloadedArtifacts, getDuration, getDurationOnAgent, getFailureReasons, getFileContent, getFirstInternalError, getFirstInternalErrorMessage, getFullName, getFullStatistics, getId, getLabels, getLogMessages, getOwner, getParametersProvider, getPreviousFinished, getProvidedArtifacts, getQueuedDate, getRecentlyFinishedBuild, getRelatedIssues, getRemoteArtifacts, getRemoteArtifactsByType, getRevisions, getSequenceBuild, getServerStartDate, getSettingsDigestFile, getSettingsDigestFromFile, getShortStatistics, getStartDate, getStatisticValue, getStatisticValues, getStatus, getTags, getTemporaryCustomDataStorage, getTestMessages, getTriggeredBy, getValueResolver, getValueResolver, getValueResolver, getVariablesProvider, getVcsRootEntries, getWaitReasons, hasBuildFinishParameters, hasBuildProblemOfType, hasTests, initMetrics, isArtifactsExists, isHasInternalArtifactsOnly, isHasRelatedIssues, isInternalError, isOutdated, isOutOfChangesSequence, isPersonalPatchAvailable, isResponsibleNeeded, isStartedOnAgent, isTimedOut, isUsedByOtherBuilds, muteBuildProblems, now, nowDate, preloadFailedTests, publishStatisticValue, resetBuildFinalParameters, setBuildStartTimes, updateExternalArtifactsInfoOnAccess
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface jetbrains.buildServer.Build
getBuildId, getBuildTypeName, getCompilationErrorMessages, getDuration, getFullName, getLogMessages, getStartDate, getTestMessages
-
Methods inherited from interface jetbrains.buildServer.serverSide.BuildPromotionOwner
getSequenceBuild
-
Methods inherited from interface jetbrains.buildServer.serverSide.ParametersSupport
getParametersProvider
-
Methods inherited from interface jetbrains.buildServer.serverSide.SBuild
addBuildProblem, convertToAgentTime, convertToServerTime, getArtifactDependencies, getArtifacts, getArtifactsDirectory, getBranch, getBuildComment, getBuildFeaturesOfType, getBuildOwnParameters, getChanges, getClientStartDate, getClientTimeZone, getCommitters, getContainingChanges, getCustomDataStorage, getDownloadedArtifacts, getFailureReasons, getFileContent, getFirstInternalError, getFirstInternalErrorMessage, getFullStatistics, getLabels, getOwner, getPreviousFinished, getProvidedArtifacts, getQueuedDate, getRecentlyFinishedBuild, getRelatedIssues, getRemoteArtifacts, getRemoteArtifactsByType, getRevisions, getServerStartDate, getShortStatistics, getStatisticValue, getStatisticValues, getTags, getTriggeredBy, getValueResolver, getVcsRootEntries, getWaitReasons, hasBuildProblemOfType, hasTests, isArtifactsExists, isHasInternalArtifactsOnly, isHasRelatedIssues, isInternalError, isOutdated, isOutOfChangesSequence, isResponsibleNeeded, isStartedOnAgent, isUsedByOtherBuilds
-
-
-
-
Constructor Detail
-
SecuredFinishedBuildImpl
public SecuredFinishedBuildImpl(long buildId, long buildPromotionId, @NotNull String buildTypeId, String agentName, int agentTypeId, @NotNull Date buildStartTimeServer, Date buildStartTimeAgent, @NotNull Date buildFinishTimeServer, @NotNull Status buildStatus, String finalStatusText, String buildNumber, boolean pin, boolean personal, CanceledInfo canceledInfo, String requestor, String buildDescription, @Nullable BuildPromotionEx buildPromotion, @NotNull BuildContext context)
-
-
Method Detail
-
setPinned
public void setPinned(boolean pinned, User user, String comment)Description copied from interface:SFinishedBuildSets pin status for this build. Pinned builds will not be cleaned by the server cleanup process.- Specified by:
setPinnedin interfaceSFinishedBuild- Overrides:
setPinnedin classFinishedBuildImpl- Parameters:
pinned- whether to pin build or not.user- user who pins/unpins buildcomment- comment
-
setBuildComment
public void setBuildComment(@Nullable User user, @Nullable String comment)Description copied from interface:SBuildSets the comment for the build- Specified by:
setBuildCommentin interfaceSBuild- Overrides:
setBuildCommentin classBaseBuild- Parameters:
user- user who sets the commentcomment- text of the comment
-
setTags
public void setTags(List<String> tags)
Description copied from interface:SBuildSets public tags for this build
-
setTags
public void setTags(User user, List<String> tags)
Description copied from interface:SBuildSets public tags for this build
-
setLabel
public void setLabel(String labelValue, List<VcsRootInstance> rootsToLabel) throws VcsException
Description copied from interface:SFinishedBuildSets a label on files in VCS repository used by this build in the specified VCS roots- Specified by:
setLabelin interfaceSFinishedBuild- Overrides:
setLabelin classFinishedBuildImpl- Parameters:
labelValue- VCS label to set (references to properties are not supported)rootsToLabel- VCS roots to label- Throws:
VcsException- if labeling failed
-
getBuildFinishParameters
public DepParametersMemoryOptimizedMap getBuildFinishParameters()
Description copied from interface:FinishedBuildExThis method returns build parameters (env, config, system) that were on build agent at the end of this build.This method may return
nullif there is no parameters were persisted- Specified by:
getBuildFinishParametersin interfaceFinishedBuildEx- Overrides:
getBuildFinishParametersin classBaseBuild- Returns:
- map of all parameters
-
getBuildStartParameters
public DepParametersMemoryOptimizedMap getBuildStartParameters()
Description copied from interface:FinishedBuildExThis method returns build parameters (env, config, system) that were on build agent before build runners are called in the build.Parameters could change during the build by pluing or build/user actions
This method may return
nullif there is no parameters were persisted- Specified by:
getBuildStartParametersin interfaceFinishedBuildEx- Overrides:
getBuildStartParametersin classBaseBuild- Returns:
- map of all parameters
-
addUserBuildProblem
public BuildProblemData addUserBuildProblem(@NotNull SUser user, @NotNull String problemDescription)
Description copied from interface:SBuildAdds user provided build problem to the build. Currently build problem causes build failure. Adding user provided problem always overrides previously added one- Specified by:
addUserBuildProblemin interfaceSBuild- Overrides:
addUserBuildProblemin classBaseBuild- Parameters:
user- user that will be used in audit- Returns:
- added build problem
-
muteBuildProblems
public void muteBuildProblems(@NotNull SUser user, boolean muteIfTrue, @NotNull String comment)Description copied from interface:SBuildMakes all existing build problems enabled or disabled- Specified by:
muteBuildProblemsin interfaceSBuild- Overrides:
muteBuildProblemsin classBaseBuild- Parameters:
user- user that will be used in auditmuteIfTrue- pass true to make build successful, false to make existing problems visible againcomment- comment for audit
-
deleteBuildProblem
public void deleteBuildProblem(@NotNull SUser user, @NotNull String identity, @Nullable String comment)Description copied from interface:BuildExDeletes build problem Deleting build problem may change build status to SUCCESS- Specified by:
deleteBuildProblemin interfaceBuildEx- Overrides:
deleteBuildProblemin classBaseBuild- Parameters:
user- user that will be used in auditidentity- identiry of build problem to be removedcomment- comment for audit
-
getDeploymentStatus
@NotNull public SortedMap<BuildTypeEx,BuildPromotionEx> getDeploymentStatus()
- Specified by:
getDeploymentStatusin interfaceFinishedBuildEx- Overrides:
getDeploymentStatusin classFinishedBuildImpl- Returns:
- map of environment build configurations depending directly on configuration of this build by snapshot or artifact dependencies to the latest triggered build promotion which is using this build. If there is no triggered build yet, then corresponding value in map entry is null.
-
getAgent
@NotNull public BuildAgentEx getAgent()
- Specified by:
getAgentin interfaceFinishedBuildEx- Specified by:
getAgentin interfaceSBuild- Overrides:
getAgentin classFinishedBuildImpl- Returns:
- agent where this build executed.
-
updatePinInfo
public void updatePinInfo()
Description copied from interface:FinishedBuildExReload pin status from the database- Specified by:
updatePinInfoin interfaceFinishedBuildEx- Overrides:
updatePinInfoin classFinishedBuildImpl
-
-