|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.bamboo.resultsummary.BuildResultsSummaryManagerImpl
public class BuildResultsSummaryManagerImpl
| Constructor Summary | |
|---|---|
BuildResultsSummaryManagerImpl()
|
|
| Method Summary | ||
|---|---|---|
void |
calculateAndSetDeltaState(ResultsSummary resultsSummary)
Figures out the delta state for the provided results summary, if a 'fixing' build will also calculate how long it took to fix. |
|
int |
countBuildResultsSummaries()
Returns the number of results saved |
|
int |
countBuildResultsSummaries(java.lang.String planKey)
Returns the number of results saved for the given Build |
|
int |
countBuildResultsSummariesForAgent(BuildAgent buildAgent)
|
|
int |
countFailedBuildResultsSummariesForAgent(BuildAgent buildAgent)
|
|
int |
countResultsWithState(PlanKey planKey,
int lowerBuildNumber,
int upperBuildNumber,
BuildState buildState)
Counts results with a given state in a given build number range for plan. |
|
|
createResultsSummary(BuildContext buildContext,
java.lang.Class<T> aClass)
Creates a ResultsSummary of the given Class |
|
java.util.List<BuildResultsSummary> |
findBuildResultsSummaries(BuildResultsSummaryCriteria criteria)
Searches for BuildResultsSummary objects given a BuildResultsSummaryCriteria |
|
java.util.List<BuildResultsSummary> |
findBuildResultsSummariesForBuild(Build build,
BuildResultsSummaryCriteria criteria)
|
|
java.util.List<ChainResultsSummary> |
findChainResultsWithJobLabelled(ResultsSummaryCriteria criteria,
java.util.List<Label> labels)
Searches through all chains to find any that have jobs which match the given labels. |
|
ResultsSummary |
findFirstFailedBuildResultAfter(java.lang.String buildKey,
int buildNumber)
Finds the first failed ResultsSummary after buildNumber |
|
ResultsSummary |
findFirstFailedBuildResultBetween(Plan build,
int lowerBuildNumber,
int upperBuildNumber)
Finds the first failed build between the upper and lower build numbers inclusively. |
|
|
findFirstResultAfter(PlanResultKey planResultKey,
java.lang.Class<T> aClass)
Finds the first ResultsSummary after a specified build which is either FINISHED or can be FINISHED, i.e. |
|
ResultsSummary |
findFirstSuccessfulBuildResultAfter(java.lang.String buildKey,
int buildNumber)
Finds the last successful BuildResultsSummary after buildNumber |
|
java.util.List<LinkedJiraIssue> |
findJiraIssuesForPlan(Plan plan)
Retrieves a list of LinkedJiraIssue linked to the given Plan |
|
java.util.List<LinkedJiraIssue> |
findJiraIssuesForResults(java.util.List<ResultsSummary> buildResults)
Retrieves a list of LinkedJiraIssue linked to the given build result summaries |
|
ResultsSummary |
findLastBuildResultBefore(java.lang.String buildKey,
int buildNumber)
Finds the last successful or failing BuildResultsSummary before buildNumber |
|
ResultsSummary |
findLastFailingBuildResultBefore(Plan build,
int buildNumber)
Finds the last failing BuildResultsSummary before buildNumber |
|
|
findLastResultBefore(PlanResultKey planResultKey,
java.lang.Class<T> aClass)
Finds the last successful or failing ResultsSummary before planResultKey.getBuildNumber |
|
|
findLastResultSummaryWithState(PlanKey planKey,
BuildState buildState,
java.lang.Class<T> aClass)
|
|
ResultsSummary |
findLastSuccessfulBuildResultBefore(Plan build,
int buildNumber)
Finds the last successful BuildResultsSummary before buildNumber |
|
java.util.List<? extends ResultsSummary> |
findResultsSummariesByJiraIssues(java.util.List<java.lang.String> issueKeys)
Finds a list of results which are linked to the given issue keys |
|
java.util.List<? extends ResultsSummary> |
findResultsSummariesByProjectKey(java.lang.String projectKey)
Provide a list of results which are linked to any issues under the given jira project key |
|
|
getAllActiveResultSummariesForPlan(PlanKey planKey,
java.lang.Class<T> aClass)
Returns all the ResultsSummary in a LifeCycleState.IN_PROGRESS state |
|
java.util.List<BuildResultsSummary> |
getAllBuildResultsSummaries(Plan plan)
Returns all BuildResultsSummary for the passed Plan. |
|
java.util.List<BuildResultsSummary> |
getAllBuildResultsSummariesForAgent(java.lang.Long agentId)
Returns all BuildResultsSummary for the passed BuildAgent's id. |
|
|
getAllBuildResultSummariesInUnknownState(java.lang.Class<T> aClass)
Returns all the BuildResultsSummary in a BuildState.UNKNOWN
state |
|
java.util.List<BuildResultsSummary> |
getAllFailedResultsSummaries(Build build)
Returns all Failed BuildResultsSummary for the passed Build. |
|
|
getAllInProgressResultSummaries(java.lang.Class<T> aClass)
Returns all the ResultsSummary in a LifeCycleState.IN_PROGRESS state |
|
|
getAllPendingResultSummaries(java.lang.Class<T> aClass)
Returns all the ResultsSummary in a LifeCycleState.PENDING state |
|
|
getAllQueuedResultSummaries(java.lang.Class<T> aClass)
Returns all the ResultsSummary in a LifeCycleState.QUEUED state |
|
|
getAllResultSummariesForPlan(Plan plan)
Get all the ResultsSummarys for the given Plan. |
|
long |
getAverageBuildTime(Buildable plan,
int numberOfResults)
Returns average build duration for given number of builds |
|
long |
getAveragePlanExecutionDuration(Plan plan,
int numberOfResults)
Get average duration from n last results summaries in finished state for a plan. |
|
ResultsSummary |
getBreakingBuild(ResultsSummary buildResultsSummary)
Returns the first failing build after the last successful build. |
|
BuildResultsSummary |
getBuildResultsSummary(Build build,
int buildNumber)
|
|
BuildResultsSummary |
getBuildResultsSummary(PlanResultKey planResultKey)
Gets the BuildResultsSummary represented by the provided PlanResultKey |
|
BuildResultsSummary |
getBuildResultsSummary(java.lang.String buildKey,
int buildNumber)
Gets the BuildResultsSummary represented by the provided buildKey and buildNumber |
|
BuildResultsSummary |
getBuildResultsSummaryById(long id)
|
|
ChainStageResult |
getChainStageResultById(java.lang.Long id)
Returns a ChainStageResult by its id |
|
java.util.List<Commit> |
getCommitsForResult(ResultsSummary resultsSummary)
|
|
|
getFinalizedResultSummariesForPlan(PlanKey planKey,
java.lang.Class<T> aClass,
int firstResult,
int maxResults)
Returns all the ResultsSummary in a LifeCycleState.FINISHED or LifeCycleState.NOT_BUILT state with the given Class. |
|
BuildResultsSummary |
getFirstBuildSummary(Plan plan)
Retreives the first result |
|
ResultsSummary |
getFixingBuild(ResultsSummary buildResultsSummary)
Returns the first successful ResultsSummary for given ResultsSummary. |
|
BuildResultsSummary |
getLastBuildForAgent(java.lang.String planKey,
java.lang.Long agentId)
|
|
BuildResultsSummary |
getLastBuildForImageConfiguration(java.lang.String planKey,
ElasticImageConfiguration configuration)
|
|
BuildResultsSummary |
getLastBuildSummary(Plan plan)
Retrieves the last completed build result for a plan |
|
BuildResultsSummary |
getLastBuildSummary(java.lang.String planKey)
Retrieves the last completed build result for a plan identified by a planKey |
|
java.util.List<BuildResultsSummary> |
getLastNBuildResultsSummaries(Buildable buildable,
int numberOfResults)
Deprecated. |
|
java.util.List<ResultsSummary> |
getLastNFailedResultsSummaries(Plan plan,
int numberOfResults)
Returns the most recent n failed build results. |
|
java.util.List<ResultsSummary> |
getLastNResultsSummaries(Plan plan,
int numberOfResults)
Provides a list of the latest N results summaries for the given plan, newest first. |
|
BuildResultsSummary |
getLastOrNBuildResultsSummary(Build build,
java.lang.String buildNumber)
Deprecated. |
|
|
getLastResultsSummary(java.lang.String planKey,
java.lang.Class<T> aClass)
Get the last ResultsSummary for planKey and Class |
|
BuildResultsSummary |
getLastSuccessfulBuildForAgent(java.lang.String planKey,
java.lang.Long agentId)
|
|
BuildResultsSummary |
getLastSuccessfulBuildForImageConfiguration(java.lang.String planKey,
ElasticImageConfiguration configuration)
|
|
BuildResultsSummary |
getLastSuccessfulBuildSummary(java.lang.String planKey)
|
|
ResultsSummary |
getLastSuccessfulResultSummary(PlanKey planKey)
Get the last successful ResultsSummary for planKey |
|
java.util.List<BuildResultsSummary> |
getLatestbuildResultSummaries()
Deprecated. |
|
java.util.List<BuildResultsSummary> |
getLatestFailedBuildResultSummaries()
Deprecated. |
|
java.util.List<ResultsSummary> |
getLatestFailedResultSummaries()
Retrieve list of failed build results (for all builds) in the last few days (number of days is specified in the DAO) This method is filtered to remove results that user doesn't have permission to see |
|
java.util.List<ResultsSummary> |
getLatestResultSummaries()
Retrieve list of build results (for all builds) in the last few days (number of days is specified in the DAO) This method is filtered to remove results that user doesn't have permission to see |
|
java.util.List<BuildResultsSummary> |
getLatestSummariesForAgent(java.lang.Long agentId,
java.util.Date fromDate)
Retrieves build summaries for agent id not older than certain date. |
|
java.util.List<BuildResultsSummary> |
getLatestSummariesForAgent(java.lang.Long agentId,
int maxCount)
Retrieves n last build summaries for agent. |
|
java.util.List<ResultsSummary> |
getNeighbouringSummaries(Plan plan,
int buildNumber)
Returns all the ResultsSummary objects that matches the passed build numbers |
|
int |
getNumberOfConcurrentlyRunningBuilds(PlanKey planKey)
Gets the number of concurrently running builds |
|
long |
getNumberOfFinalizedResults(Plan plan)
Get number of the ResultsSummarys in a LifeCycleState.FINISHED or LifeCycleState.NOT_BUILT state for the given Plan |
|
long |
getNumberOfFinishedResults(Plan plan)
Get number of the ResultsSummarys in LifeCycleState.FINISHED state for the given Plan |
|
ChainResultsSummary |
getParentResultSummary(ResultsSummary resultsSummary)
Get (@link ChainResultsSummary} containing given ResultsSummary |
|
ResultsSummary |
getResultsSummary(PlanResultKey planResultKey)
Lookup the ResultsSummary by PlanResultKey |
|
|
getResultsSummary(PlanResultKey planResultKey,
java.lang.Class<T> aClass)
Lookup ResultsSummary by PlanResultKey and expected type |
|
|
getResultsSummary(PlanResultKey planResultKey,
java.lang.Class<T> aClass,
ResultDataRead dataRead)
Lookup ResultsSummary by PlanResultKey and expected type. |
|
ResultsSummary |
getResultsSummary(PlanResultKey planResultKey,
ResultDataRead dataRead)
Lookup the ResultsSummary by PlanResultKey. |
|
|
getResultSummaries(ResultsSummaryCriteria resultsSummaryCriteria)
Generic search to find any result summaries bases on the criteria provided. |
|
|
getResultSummariesForPlan(Plan plan,
int firstResult,
int maxResults)
Get the ResultsSummarys for the given Plan in any LifeCycleState. |
|
|
getResultSummariesForPlanByLifeCycleState(Plan plan,
LifeCycleState lifeCycleState,
int firstResult,
int maxResults)
Get the ResultsSummarys for the given Plan in give LifeCycleState that are Results are sorted by build number (descending). |
|
ChainStageResult |
getStageForResult(ResultsSummary resultsSummary)
Get (@link ChainStageResult} containing given ResultsSummary |
|
void |
logSubstitutedVariables(BuildContext buildContext,
ResultsSummary resultsSummary)
Adds variable substitution result to ResultsSummary
This method logs substitution after it was performed and will use only REALLY substituted values |
|
void |
logVariablesForSubstitution(BuildContext buildContext,
ResultsSummary resultsSummary)
Adds expected variable substitution to ResultsSummary
This method logs substitution before build was performed and is used basically to log substitution against plan result
as there will be no possibility to track it afterwards |
|
void |
moveResultSummaries(PlanKey oldPlanKey,
PlanKey newPlanKey)
Reassigns plan key ResultsSummaries associated with selected plan key. |
|
int |
removeAllOrphanedResultSummaries()
Removes all the ResultsSummary objects in the database that do not have a matching Plan |
|
void |
removeArtifacts(Plan plan,
int buildNumber)
Remove any artifacts stored for this plan result |
|
void |
removeBuildLogs(Plan plan,
int buildNumber)
Remove any build logs stored for this plan result |
|
void |
removeBuildResult(Buildable buildable,
int buildNumber)
Removes a build result for a particular build. |
|
void |
removeBuildResultsSummariesForBuild(Build build)
Deprecated. |
|
void |
removeMatchingArtifacts(ResultsSummary resultsSummary,
com.google.common.base.Predicate<ArtifactLink> predicate)
Remove artifacts from results summary that match a predicate. |
|
int |
removeResultsSummariesForPlan(Plan plan)
Remove all resultSummary objects for the given plan. |
|
void |
removeResultSummary(Plan plan,
int buildNumber)
Remove plan result summary and all associated objects. |
|
void |
saveBuildResultsSummary(BuildResultsSummary buildResultsSummary)
Saves the specified BuildResultsSummary |
|
void |
saveResultSummary(ResultsSummary resultsSummary)
Saves the ResultsSummary |
|
long |
scrollResultSummaries(java.lang.String buildKey,
com.google.common.base.Function<ResultsSummary,java.lang.Void> function)
Scroll through and execute function for each of BuildResultsSummary Objects passed to function are not fully initialized. |
|
long |
scrollResultSummaries(java.lang.String buildKey,
ResultDataRead resultDataRead,
com.google.common.base.Function<ResultsSummary,java.lang.Void> function)
Scroll through and execute function for each of BuildResultsSummary Objects passed to function are not fully initialized. |
|
void |
setArtifactLinkManager(ArtifactLinkManager artifactLinkManager)
|
|
void |
setBuildExecutionManager(BuildExecutionManager buildExecutionManager)
|
|
void |
setBuildResultsIndexer(BuildResultsIndexer buildResultsIndexer)
|
|
void |
setBuildResultsSummaryDao(BuildResultsSummaryDao buildResultsSummaryDao)
|
|
void |
setCommitDao(CommitDao commitDao)
|
|
void |
setEventManager(com.atlassian.event.EventManager eventManager)
|
|
void |
setExtendedAuthorManager(ExtendedAuthorManager extendedAuthorManager)
|
|
void |
setJiraIssueManager(JiraIssueManager jiraIssueManager)
|
|
void |
setJiraIssueUtils(JiraIssueUtils jiraIssueUtils)
|
|
BuildResultsSummary |
updateBuildState(BuildResultsSummary buildResultsSummary,
BuildState buildState)
Update the BuildState of the BuildResultsSummary |
|
BuildResultsSummary |
updateBuildSummaryFromBuildResults(BuildContext buildContext,
CurrentlyBuilding currentlyBuilding,
BuildResults buildResults)
Updates BuildResultsSummary after build is completed. |
|
void |
updateCancelledDetails(ResultsSummary resultsSummary)
Marks ResultSummary as cancelled |
|
void |
updateLifeCycleState(BuildContext buildContext,
LifeCycleState lifeCycleState,
BuildState buildState)
Update LifeCycleState and saves the ResultsSummary for given BuildContext
Updates also timing information |
|
void |
updateLifeCycleState(ResultsSummary resultsSummary,
LifeCycleState lifeCycleState,
BuildState buildState)
Update LifeCycleState and saves the given ResultsSummary |
|
void |
updatePlanCompletedDate(ResultsSummary resultSummary,
java.util.Date completionDate)
Update completed date and duration of ResultsSummary |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BuildResultsSummaryManagerImpl()
| Method Detail |
|---|
@NotNull
public <T extends ResultsSummary> java.util.List<T> getAllResultSummariesForPlan(@NotNull
Plan plan)
ResultsSummaryManagerResultsSummarys for the given Plan. This can be thousands of objects or just a few. Avoid using this method at all costs.
getAllResultSummariesForPlan in interface ResultsSummaryManager
@NotNull
public <T extends ResultsSummary> java.util.List<T> getResultSummariesForPlanByLifeCycleState(@NotNull
Plan plan,
@NotNull
LifeCycleState lifeCycleState,
int firstResult,
int maxResults)
ResultsSummaryManagerResultsSummarys for the given Plan in give LifeCycleState that are Results are sorted by build number (descending). User
can skip first n result and request maximum number of results.
getResultSummariesForPlanByLifeCycleState in interface ResultsSummaryManagerfirstResult - specifies the first item to be return (0 base index). Negative values treated as 0.maxResults - specifies amount of the results to be returned. Value <= 0 returns everything.
@NotNull
public <T extends ResultsSummary> java.util.List<T> getResultSummariesForPlan(@NotNull
Plan plan,
int firstResult,
int maxResults)
ResultsSummaryManagerResultsSummarys for the given Plan in any LifeCycleState. Results are sorted by build number (descending). User can skip first n result
and request maximum number of results.
getResultSummariesForPlan in interface ResultsSummaryManagerfirstResult - specifies the first item to be return (0 base index). Negative values treated as 0.maxResults - specifies amount of the results to be returned. Value <= 0 returns everything.
@Nullable
public ChainStageResult getChainStageResultById(@NotNull
java.lang.Long id)
ResultsSummaryManagerChainStageResult by its id
getChainStageResultById in interface ResultsSummaryManager
@Nullable
public ResultsSummary getResultsSummary(@NotNull
PlanResultKey planResultKey)
ResultsSummaryManagerPlanResultKey
getResultsSummary in interface ResultsSummaryManager
@Nullable
public ResultsSummary getResultsSummary(@NotNull
PlanResultKey planResultKey,
ResultDataRead dataRead)
ResultsSummaryManagerPlanResultKey. All lazy initialized collections can be eagerly fetched to avoid session problems.
Use with caution - expensive call
getResultsSummary in interface ResultsSummaryManager
@Nullable
public <T extends ResultsSummary> T getResultsSummary(@NotNull
PlanResultKey planResultKey,
@NotNull
java.lang.Class<T> aClass)
ResultsSummaryManagerResultsSummary by PlanResultKey and expected type
getResultsSummary in interface ResultsSummaryManager
@Nullable
public <T extends ResultsSummary> T getResultsSummary(@NotNull
PlanResultKey planResultKey,
@NotNull
java.lang.Class<T> aClass,
ResultDataRead dataRead)
ResultsSummaryManagerResultsSummary by PlanResultKey and expected type. All lazy initialized collections can be eagerly fetched to avoid session problems.
Use with caution - expensive call
getResultsSummary in interface ResultsSummaryManager@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllPendingResultSummaries(java.lang.Class<T> aClass)
ResultsSummaryManagerResultsSummary in a LifeCycleState.PENDING state
getAllPendingResultSummaries in interface ResultsSummaryManager@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllQueuedResultSummaries(java.lang.Class<T> aClass)
ResultsSummaryManagerResultsSummary in a LifeCycleState.QUEUED state
getAllQueuedResultSummaries in interface ResultsSummaryManager@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllInProgressResultSummaries(java.lang.Class<T> aClass)
ResultsSummaryManagerResultsSummary in a LifeCycleState.IN_PROGRESS state
getAllInProgressResultSummaries in interface ResultsSummaryManager
@NotNull
public <T extends ResultsSummary> java.util.Collection<T> getAllActiveResultSummariesForPlan(PlanKey planKey,
java.lang.Class<T> aClass)
ResultsSummaryManagerResultsSummary in a LifeCycleState.IN_PROGRESS state
getAllActiveResultSummariesForPlan in interface ResultsSummaryManager
@NotNull
public <T extends ResultsSummary> java.util.List<T> getFinalizedResultSummariesForPlan(PlanKey planKey,
java.lang.Class<T> aClass,
int firstResult,
int maxResults)
ResultsSummaryManagerResultsSummary in a LifeCycleState.FINISHED or LifeCycleState.NOT_BUILT state with the given Class.
Results are sorted descending by build number.
getFinalizedResultSummariesForPlan in interface ResultsSummaryManagerfirstResult - - specifies the first result to be included in the list.maxResults - - specifies the length of the result; 0 for all results;
public int getNumberOfConcurrentlyRunningBuilds(PlanKey planKey)
ResultsSummaryManager
getNumberOfConcurrentlyRunningBuilds in interface ResultsSummaryManager@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllBuildResultSummariesInUnknownState(java.lang.Class<T> aClass)
ResultsSummaryManagerBuildResultsSummary in a BuildState.UNKNOWN
state
getAllBuildResultSummariesInUnknownState in interface ResultsSummaryManager
public <T extends ResultsSummary> T createResultsSummary(@NotNull
BuildContext buildContext,
@NotNull
java.lang.Class<T> aClass)
throws ResultsSummaryCreationException
ResultsSummaryManagerResultsSummary of the given Class
createResultsSummary in interface ResultsSummaryManagerResultsSummaryCreationException
@NotNull
public BuildResultsSummary updateBuildSummaryFromBuildResults(BuildContext buildContext,
CurrentlyBuilding currentlyBuilding,
BuildResults buildResults)
BuildResultsSummaryManager
updateBuildSummaryFromBuildResults in interface BuildResultsSummaryManagerpublic void calculateAndSetDeltaState(ResultsSummary resultsSummary)
ResultsSummaryManager
calculateAndSetDeltaState in interface ResultsSummaryManagerresultsSummary - to update
@NotNull
public BuildResultsSummary updateBuildState(@NotNull
BuildResultsSummary buildResultsSummary,
@NotNull
BuildState buildState)
BuildResultsSummaryManagerBuildState of the BuildResultsSummary
updateBuildState in interface BuildResultsSummaryManager
public void updateLifeCycleState(@NotNull
ResultsSummary resultsSummary,
@NotNull
LifeCycleState lifeCycleState,
@NotNull
BuildState buildState)
ResultsSummaryManagerResultsSummary
updateLifeCycleState in interface ResultsSummaryManagerresultsSummary - ResultsSummary to be updated and savedlifeCycleState - LifeCycleState to be setbuildState - BuildState to be set
public void updateLifeCycleState(@NotNull
BuildContext buildContext,
@NotNull
LifeCycleState lifeCycleState,
@NotNull
BuildState buildState)
ResultsSummaryManagerResultsSummary for given BuildContext
Updates also timing information
updateLifeCycleState in interface ResultsSummaryManagerbuildContext - BuildContext used to get information on ResultsSummarylifeCycleState - LifeCycleState to be setbuildState - BuildState to be set
public void updatePlanCompletedDate(@NotNull
ResultsSummary resultSummary,
@NotNull
java.util.Date completionDate)
ResultsSummaryManagerResultsSummary
updatePlanCompletedDate in interface ResultsSummaryManager@Nullable public ResultsSummary getBreakingBuild(ResultsSummary buildResultsSummary)
ResultsSummaryManager
getBreakingBuild in interface ResultsSummaryManagerbuildResultsSummary - of the current build
@Nullable public ResultsSummary getFixingBuild(ResultsSummary buildResultsSummary)
ResultsSummaryManagerResultsSummary for given ResultsSummary. The input build
is returned if it is successful.
getFixingBuild in interface ResultsSummaryManager
@NotNull
public java.util.List<BuildResultsSummary> getAllBuildResultsSummaries(@NotNull
Plan plan)
BuildResultsSummaryManagerBuildResultsSummary for the passed Plan. Sorted by oldest first.
getAllBuildResultsSummaries in interface BuildResultsSummaryManager
@NotNull
public java.util.List<BuildResultsSummary> getAllFailedResultsSummaries(@NotNull
Build build)
BuildResultsSummaryManagerBuildResultsSummary for the passed Build. Sorted by oldest first.
getAllFailedResultsSummaries in interface BuildResultsSummaryManager
@Deprecated
@NotNull
public java.util.List<BuildResultsSummary> getLastNBuildResultsSummaries(@NotNull
Buildable buildable,
int numberOfResults)
ResultsSummaryManager
getLastNBuildResultsSummaries in interface ResultsSummaryManagernumberOfResults - must be > 0 @return
@NotNull
public <T extends ResultsSummary> java.util.List<T> getResultSummaries(@NotNull
ResultsSummaryCriteria resultsSummaryCriteria)
ResultsSummaryManager
getResultSummaries in interface ResultsSummaryManagerresultsSummaryCriteria - containing all the search constraints
@NotNull
public java.util.List<ResultsSummary> getLastNResultsSummaries(@NotNull
Plan plan,
int numberOfResults)
ResultsSummaryManager
getLastNResultsSummaries in interface ResultsSummaryManagerplan - - to get the results fornumberOfResults - - number of summaries you would like
@Deprecated
@Nullable
public BuildResultsSummary getLastOrNBuildResultsSummary(@NotNull
Build build,
@Nullable
java.lang.String buildNumber)
getLastOrNBuildResultsSummary in interface BuildResultsSummaryManager
@NotNull
public java.util.List<ResultsSummary> getLastNFailedResultsSummaries(@NotNull
Plan plan,
int numberOfResults)
ResultsSummaryManager
getLastNFailedResultsSummaries in interface ResultsSummaryManagernumberOfResults - must be > 0
@NotNull
public java.util.List<BuildResultsSummary> findBuildResultsSummaries(@NotNull
BuildResultsSummaryCriteria criteria)
BuildResultsSummaryManagerBuildResultsSummary objects given a BuildResultsSummaryCriteria
findBuildResultsSummaries in interface BuildResultsSummaryManagercriteria - @NotNull
List of BuildResultsSummary
public java.util.List<BuildResultsSummary> findBuildResultsSummariesForBuild(@NotNull
Build build,
@NotNull
BuildResultsSummaryCriteria criteria)
findBuildResultsSummariesForBuild in interface BuildResultsSummaryManagerpublic int countBuildResultsSummaries()
BuildResultsSummaryManager
countBuildResultsSummaries in interface BuildResultsSummaryManager
public int countBuildResultsSummaries(@Nullable
java.lang.String planKey)
BuildResultsSummaryManagerBuild
countBuildResultsSummaries in interface BuildResultsSummaryManager
@NotNull
public java.util.List<? extends ResultsSummary> findResultsSummariesByJiraIssues(@Nullable
java.util.List<java.lang.String> issueKeys)
ResultsSummaryManager
findResultsSummariesByJiraIssues in interface ResultsSummaryManagerissueKeys - to search for
@NotNull
public java.util.List<? extends ResultsSummary> findResultsSummariesByProjectKey(@Nullable
java.lang.String projectKey)
ResultsSummaryManager
findResultsSummariesByProjectKey in interface ResultsSummaryManagerprojectKey - - jira project key
@NotNull
public java.util.List<LinkedJiraIssue> findJiraIssuesForResults(@NotNull
java.util.List<ResultsSummary> buildResults)
ResultsSummaryManagerLinkedJiraIssue linked to the given build result summaries
findJiraIssuesForResults in interface ResultsSummaryManagerbuildResults - to look for issues attached to
LinkedJiraIssue linked to the given build result summaries
@NotNull
public java.util.List<LinkedJiraIssue> findJiraIssuesForPlan(@NotNull
Plan plan)
ResultsSummaryManagerLinkedJiraIssue linked to the given Plan
findJiraIssuesForPlan in interface ResultsSummaryManagerplan - to look for issues associated with
LinkedJiraIssue linked to the given Plan
public void removeResultSummary(@NotNull
Plan plan,
int buildNumber)
ResultsSummaryManager
removeResultSummary in interface ResultsSummaryManager
public void removeBuildResult(Buildable buildable,
int buildNumber)
BuildResultsSummaryManager
removeBuildResult in interface BuildResultsSummaryManagerbuildNumber - The build numner.
public void removeBuildLogs(Plan plan,
int buildNumber)
ResultsSummaryManager
removeBuildLogs in interface ResultsSummaryManager
public void removeMatchingArtifacts(@NotNull
ResultsSummary resultsSummary,
@NotNull
com.google.common.base.Predicate<ArtifactLink> predicate)
ResultsSummaryManager
removeMatchingArtifacts in interface ResultsSummaryManager
public void removeArtifacts(Plan plan,
int buildNumber)
ResultsSummaryManager
removeArtifacts in interface ResultsSummaryManager
public java.util.List<ChainResultsSummary> findChainResultsWithJobLabelled(ResultsSummaryCriteria criteria,
java.util.List<Label> labels)
ResultsSummaryManager
findChainResultsWithJobLabelled in interface ResultsSummaryManagercriteria - containing the restrictions for the chains to be returnedlabels - that the jobs can be associated with
@Nullable public BuildResultsSummary getBuildResultsSummaryById(long id)
getBuildResultsSummaryById in interface BuildResultsSummaryManager
@Nullable
public BuildResultsSummary getBuildResultsSummary(Build build,
int buildNumber)
getBuildResultsSummary in interface BuildResultsSummaryManager
@NotNull
public java.util.List<ResultsSummary> getNeighbouringSummaries(Plan plan,
int buildNumber)
ResultsSummaryManagerResultsSummary objects that matches the passed build numbers
getNeighbouringSummaries in interface ResultsSummaryManagerbuildNumber - @return List of BuildResultsSummary
@Deprecated
public void removeBuildResultsSummariesForBuild(@NotNull
Build build)
BuildResultsSummaryManagerBuildResultsSummary objects from the database. No events are triggered
removeBuildResultsSummariesForBuild in interface BuildResultsSummaryManagerbuild - @NotNull
public int removeResultsSummariesForPlan(@NotNull
Plan plan)
ResultsSummaryManagerResultsSummary objects to be deleted
in such case #scheduleResultsSummariesForDelayedDeletion(Plan) should be considered.
removeResultsSummariesForPlan in interface ResultsSummaryManagerplan - to remove results for.
ResultsSummarys removedpublic int removeAllOrphanedResultSummaries()
ResultsSummaryManagerResultsSummary objects in the database that do not have a matching Plan
removeAllOrphanedResultSummaries in interface ResultsSummaryManagerResultsSummarys removed
@Nullable
public BuildResultsSummary getBuildResultsSummary(@NotNull
PlanResultKey planResultKey)
BuildResultsSummaryManagerBuildResultsSummary represented by the provided PlanResultKey
getBuildResultsSummary in interface BuildResultsSummaryManager
@Nullable
public BuildResultsSummary getBuildResultsSummary(java.lang.String buildKey,
int buildNumber)
BuildResultsSummaryManagerBuildResultsSummary represented by the provided buildKey and buildNumber
getBuildResultsSummary in interface BuildResultsSummaryManager
public void saveBuildResultsSummary(@NotNull
BuildResultsSummary buildResultsSummary)
BuildResultsSummaryManagerBuildResultsSummary
saveBuildResultsSummary in interface BuildResultsSummaryManager
public void saveResultSummary(@NotNull
ResultsSummary resultsSummary)
ResultsSummaryManagerResultsSummary
saveResultSummary in interface ResultsSummaryManager@Nullable public BuildResultsSummary getFirstBuildSummary(Plan plan)
BuildResultsSummaryManager
getFirstBuildSummary in interface BuildResultsSummaryManager
@Nullable
public BuildResultsSummary getLastBuildSummary(@NotNull
Plan plan)
BuildResultsSummaryManager
getLastBuildSummary in interface BuildResultsSummaryManagerplan - plan of which build result will be searched
@Nullable public BuildResultsSummary getLastBuildSummary(java.lang.String planKey)
BuildResultsSummaryManager
getLastBuildSummary in interface BuildResultsSummaryManagerplanKey - identifier of a plan
public BuildResultsSummary getLastSuccessfulBuildSummary(@NotNull
java.lang.String planKey)
getLastSuccessfulBuildSummary in interface BuildResultsSummaryManager
public ResultsSummary getLastSuccessfulResultSummary(@NotNull
PlanKey planKey)
ResultsSummaryManagerResultsSummary for planKey
getLastSuccessfulResultSummary in interface ResultsSummaryManager
@Nullable
public BuildResultsSummary getLastBuildForAgent(@NotNull
java.lang.String planKey,
@NotNull
java.lang.Long agentId)
getLastBuildForAgent in interface BuildResultsSummaryManager
@Nullable
public BuildResultsSummary getLastBuildForImageConfiguration(@NotNull
java.lang.String planKey,
@NotNull
ElasticImageConfiguration configuration)
getLastBuildForImageConfiguration in interface BuildResultsSummaryManager
@Nullable
public BuildResultsSummary getLastSuccessfulBuildForAgent(@NotNull
java.lang.String planKey,
@NotNull
java.lang.Long agentId)
getLastSuccessfulBuildForAgent in interface BuildResultsSummaryManager
@Nullable
public BuildResultsSummary getLastSuccessfulBuildForImageConfiguration(@NotNull
java.lang.String planKey,
@NotNull
ElasticImageConfiguration configuration)
getLastSuccessfulBuildForImageConfiguration in interface BuildResultsSummaryManager
public int countBuildResultsSummariesForAgent(@NotNull
BuildAgent buildAgent)
countBuildResultsSummariesForAgent in interface BuildResultsSummaryManager
public int countFailedBuildResultsSummariesForAgent(@NotNull
BuildAgent buildAgent)
countFailedBuildResultsSummariesForAgent in interface BuildResultsSummaryManager
@NotNull
public java.util.List<Commit> getCommitsForResult(@NotNull
ResultsSummary resultsSummary)
getCommitsForResult in interface BuildResultsSummaryManager
@Nullable
public ResultsSummary findLastSuccessfulBuildResultBefore(@NotNull
Plan build,
int buildNumber)
ResultsSummaryManagerBuildResultsSummary before buildNumber
findLastSuccessfulBuildResultBefore in interface ResultsSummaryManager
@Nullable
public <T extends ResultsSummary> T findFirstResultAfter(@NotNull
PlanResultKey planResultKey,
java.lang.Class<T> aClass)
ResultsSummaryManagerResultsSummary after a specified build which is either FINISHED or can be FINISHED, i.e. is not
in NOT_BUILT state.
findFirstResultAfter in interface ResultsSummaryManager
@Nullable
public <T extends ResultsSummary> T findLastResultBefore(@NotNull
PlanResultKey planResultKey,
java.lang.Class<T> aClass)
ResultsSummaryManagerResultsSummary before planResultKey.getBuildNumber
findLastResultBefore in interface ResultsSummaryManager
public <T extends ResultsSummary> T findLastResultSummaryWithState(@NotNull
PlanKey planKey,
@NotNull
BuildState buildState,
@NotNull
java.lang.Class<T> aClass)
findLastResultSummaryWithState in interface ResultsSummaryManagerResultsSummary with the provided BuildState
@Nullable
public ResultsSummary findLastBuildResultBefore(@NotNull
java.lang.String buildKey,
int buildNumber)
ResultsSummaryManagerBuildResultsSummary before buildNumber
findLastBuildResultBefore in interface ResultsSummaryManager
@Nullable
public ResultsSummary findFirstFailedBuildResultAfter(@NotNull
java.lang.String buildKey,
int buildNumber)
ResultsSummaryManagerResultsSummary after buildNumber
findFirstFailedBuildResultAfter in interface ResultsSummaryManager
@Nullable
public ResultsSummary findFirstSuccessfulBuildResultAfter(@NotNull
java.lang.String buildKey,
int buildNumber)
ResultsSummaryManagerBuildResultsSummary after buildNumber
findFirstSuccessfulBuildResultAfter in interface ResultsSummaryManager
@Nullable
public ResultsSummary findLastFailingBuildResultBefore(@NotNull
Plan build,
int buildNumber)
ResultsSummaryManagerBuildResultsSummary before buildNumber
findLastFailingBuildResultBefore in interface ResultsSummaryManager
@Nullable
public ResultsSummary findFirstFailedBuildResultBetween(@NotNull
Plan build,
int lowerBuildNumber,
int upperBuildNumber)
ResultsSummaryManager
findFirstFailedBuildResultBetween in interface ResultsSummaryManager
@NotNull
public java.util.List<BuildResultsSummary> getAllBuildResultsSummariesForAgent(@NotNull
java.lang.Long agentId)
ResultsSummaryManagerBuildResultsSummary for the passed BuildAgent's id.
getAllBuildResultsSummariesForAgent in interface ResultsSummaryManageragentId - id of the agent to get the result summaries for
BuildResultsSummary for the passed BuildAgent's id.
@NotNull
public java.util.List<BuildResultsSummary> getLatestSummariesForAgent(@NotNull
java.lang.Long agentId,
@NotNull
java.util.Date fromDate)
ResultsSummaryManager
getLatestSummariesForAgent in interface ResultsSummaryManageragentId - id of an agentfromDate - beginning of the search period
List of BuildResultsSummary
@NotNull
public java.util.List<BuildResultsSummary> getLatestSummariesForAgent(@NotNull
java.lang.Long agentId,
int maxCount)
ResultsSummaryManager
getLatestSummariesForAgent in interface ResultsSummaryManageragentId - id of an agentmaxCount - maximum number of elements to retrieve
List of BuildResultsSummary@Nullable public ChainResultsSummary getParentResultSummary(ResultsSummary resultsSummary)
ResultsSummaryManagerResultsSummary
getParentResultSummary in interface ResultsSummaryManager@Nullable public ChainStageResult getStageForResult(ResultsSummary resultsSummary)
ResultsSummaryManagerResultsSummary
getStageForResult in interface ResultsSummaryManagerpublic long getNumberOfFinishedResults(Plan plan)
ResultsSummaryManagerResultsSummarys in LifeCycleState.FINISHED state for the given Plan
getNumberOfFinishedResults in interface BuildResultsSummaryManagergetNumberOfFinishedResults in interface ResultsSummaryManager
public long getNumberOfFinalizedResults(@NotNull
Plan plan)
ResultsSummaryManagerResultsSummarys in a LifeCycleState.FINISHED or LifeCycleState.NOT_BUILT state for the given Plan
getNumberOfFinalizedResults in interface ResultsSummaryManager@Deprecated public java.util.List<BuildResultsSummary> getLatestbuildResultSummaries()
BuildResultsSummaryManager
getLatestbuildResultSummaries in interface BuildResultsSummaryManagerList of BuildResultsSummary@Deprecated public java.util.List<BuildResultsSummary> getLatestFailedBuildResultSummaries()
BuildResultsSummaryManager
getLatestFailedBuildResultSummaries in interface BuildResultsSummaryManagerList of BuildResultsSummarypublic java.util.List<ResultsSummary> getLatestResultSummaries()
ResultsSummaryManager
getLatestResultSummaries in interface ResultsSummaryManagerList of ResultsSummarypublic java.util.List<ResultsSummary> getLatestFailedResultSummaries()
ResultsSummaryManager
getLatestFailedResultSummaries in interface ResultsSummaryManagerList of ResultsSummary
public long getAverageBuildTime(@NotNull
Buildable plan,
int numberOfResults)
BuildResultsSummaryManager
getAverageBuildTime in interface BuildResultsSummaryManagernumberOfResults - - How many build results to use in the average. must be greater 0 @return Average build time. 0 if no build found.
public long getAveragePlanExecutionDuration(@NotNull
Plan plan,
int numberOfResults)
ResultsSummaryManager
getAveragePlanExecutionDuration in interface ResultsSummaryManagernumberOfResults - amount of results to be taken into account for average calculation
public int countResultsWithState(@NotNull
PlanKey planKey,
int lowerBuildNumber,
int upperBuildNumber,
@NotNull
BuildState buildState)
ResultsSummaryManager
countResultsWithState in interface ResultsSummaryManagerplanKey - the key of plan to analyselowerBuildNumber - the build number to start the count withupperBuildNumber - the build number to end the count withbuildState - the state that will be counted
@Nullable
public <T extends ResultsSummary> T getLastResultsSummary(@NotNull
java.lang.String planKey,
java.lang.Class<T> aClass)
ResultsSummaryManagerResultsSummary for planKey and Class
getLastResultsSummary in interface ResultsSummaryManager
public void updateCancelledDetails(@NotNull
ResultsSummary resultsSummary)
ResultsSummaryManager
updateCancelledDetails in interface ResultsSummaryManagerresultsSummary - results summary
public void moveResultSummaries(PlanKey oldPlanKey,
PlanKey newPlanKey)
ResultsSummaryManager
moveResultSummaries in interface ResultsSummaryManager
public long scrollResultSummaries(@NotNull
java.lang.String buildKey,
@NotNull
com.google.common.base.Function<ResultsSummary,java.lang.Void> function)
ResultsSummaryManager
scrollResultSummaries in interface ResultsSummaryManagerbuildKey - of the plan you want to scroll the result summaries forfunction - function to be executed on each of the BuildResultSummary
public long scrollResultSummaries(@NotNull
java.lang.String buildKey,
ResultDataRead resultDataRead,
@NotNull
com.google.common.base.Function<ResultsSummary,java.lang.Void> function)
ResultsSummaryManager
scrollResultSummaries in interface ResultsSummaryManagerbuildKey - of the plan you want to scroll the result summaries forresultDataRead - if the data should be loaded lazy or eagerlyfunction - function to be executed on each of the BuildResultSummary
public void logVariablesForSubstitution(@NotNull
BuildContext buildContext,
@NotNull
ResultsSummary resultsSummary)
ResultsSummaryManagerResultsSummary
This method logs substitution before build was performed and is used basically to log substitution against plan result
as there will be no possibility to track it afterwards
logVariablesForSubstitution in interface ResultsSummaryManager
public void logSubstitutedVariables(@NotNull
BuildContext buildContext,
@NotNull
ResultsSummary resultsSummary)
ResultsSummaryManagerResultsSummary
This method logs substitution after it was performed and will use only REALLY substituted values
logSubstitutedVariables in interface ResultsSummaryManagerpublic void setBuildResultsSummaryDao(BuildResultsSummaryDao buildResultsSummaryDao)
public void setExtendedAuthorManager(ExtendedAuthorManager extendedAuthorManager)
public void setBuildResultsIndexer(BuildResultsIndexer buildResultsIndexer)
public void setEventManager(com.atlassian.event.EventManager eventManager)
public void setJiraIssueUtils(JiraIssueUtils jiraIssueUtils)
public void setJiraIssueManager(JiraIssueManager jiraIssueManager)
public void setArtifactLinkManager(ArtifactLinkManager artifactLinkManager)
public void setCommitDao(CommitDao commitDao)
public void setBuildExecutionManager(BuildExecutionManager buildExecutionManager)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||