|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.dao.support.DaoSupport org.springframework.orm.hibernate.support.HibernateDaoSupport com.atlassian.bamboo.persistence3.BambooHibernateObjectDao<ResultsSummary> com.atlassian.bamboo.resultsummary.BuildResultsSummaryHibernateDao
public class BuildResultsSummaryHibernateDao
Field Summary | |
---|---|
protected static java.lang.String |
BUILD_AGENT_ID
|
protected static java.lang.String |
BUILD_COMPLETED_DATE
|
protected static java.lang.String |
BUILD_NUMBER
|
protected static java.lang.String |
BUILD_STATE
|
protected static java.lang.String |
CREATION_DATE
|
protected static java.lang.String |
DELTA_STATE
|
protected static java.lang.String |
LIFE_CYCLE_STATE
|
protected static java.lang.String |
PLAN_KEY
|
Fields inherited from class org.springframework.dao.support.DaoSupport |
---|
logger |
Fields inherited from interface com.atlassian.bamboo.resultsummary.BuildResultsSummaryDao |
---|
NUMBER_OF_DAYS_TO_FILTER |
Constructor Summary | |
---|---|
BuildResultsSummaryHibernateDao()
|
Method Summary | ||
---|---|---|
int |
countBuildResultsSummaries()
Count all result summaries records. |
|
int |
countBuildResultsSummaries(long agentId,
BuildState buildState)
Count how many build results match the agent & optional build state. |
|
int |
countBuildResultsSummaries(java.lang.String planKey)
|
|
int |
countResultsWithState(PlanKey planKey,
int lowerBuildNumber,
int upperBuildNumber,
BuildState buildState)
Counts results with a given state in a given build number range for plan. |
|
java.util.List<ResultsSummary> |
findBuildResultsSummariesByJiraIssues(java.util.List<java.lang.String> issueKeys)
Get a list of results summaries associated with the list of issue keys. |
|
java.util.List<ResultsSummary> |
findBuildResultsSummariesByProjectKey(java.lang.String jiraProjectKey)
Retrieve a list of results summaries associated with given JIRA project key This will not return records marked for deletion. |
|
java.util.List<Pair<ArtifactLink,BuildResultsSummary>> |
findBuildResultsWithArtifacts(java.lang.String planKey)
Find all build results which have matching artifacts. |
|
java.util.List<BuildResultsSummary> |
findBuildsForImageConfiguration(java.lang.String planKey,
ElasticImageConfiguration elasticImage,
BuildState buildState,
int maxResults)
Searcher for builds of an image |
|
|
findById(long id,
java.lang.Class<E> aClass)
Find an entity by its id |
|
java.util.List<ChainResultsSummary> |
findChainResultsWithJobLabelled(ResultsSummaryCriteria queryCriteria,
java.util.List<Label> labels)
Searches through all chains to find any that have jobs which match the given labels. |
|
java.lang.Integer |
findFirstBuildNumberAfter(java.lang.String planKey,
int buildNumber)
Returns the build number of next existing build results. |
|
ResultsSummary |
findFirstBuildResultWithBuildStateAfter(java.lang.String planKey,
int buildNumber,
BuildState buildState)
Finds the last successful BuildResultsSummary after buildNumber |
|
ResultsSummary |
findFirstBuildResultWithBuildStateBetween(java.lang.String planKey,
int lowerBuildNumber,
int upperBuildNumber,
BuildState buildState)
Returns the first build that matches BuildState between the given build number range
Note that this function is inclusive of the upper and lower bound |
|
|
findFirstResultAfter(java.lang.String planKey,
int buildNumber,
java.lang.Class<T> aClass)
Finds the first successful or failed BuildResultsSummary after buildNumber |
|
java.lang.Integer |
findLastBuildNumberBefore(java.lang.String planKey,
int buildNumber)
Returns the build number of previous existing build results. |
|
|
findLastBuildResultBeforeWithTests(PlanResultKey planResultKey,
java.lang.Class<T> aClass)
|
|
ResultsSummary |
findLastBuildResultWithBuildStateBefore(java.lang.String planKey,
int buildNumber,
BuildState buildState)
Finds the last BuildResultsSummary before buildNumber with BuildState |
|
|
findLastResultBefore(java.lang.String planKey,
int buildNumber,
java.lang.Class<T> aClass)
Finds the last successful or failed ResultsSummary before buildNumber |
|
|
findLastResultSummaryWithState(PlanKey planKey,
BuildState buildState,
java.lang.Class<T> aClass)
|
|
java.util.List<ResultsSummary> |
findLatestFailedResultSummaries()
Find the failed result summaries for all TopLevelPlans in Bamboo that have occurred in the last X days, where x is the constant NUMBER_OF_DAYS_TO_FILTER |
|
java.util.List<ResultsSummary> |
findLatestResultsSummaries()
Find the result summaries for all TopLevelPlans in Bamboo that have occurred in the last X days, where x is the constant NUMBER_OF_DAYS_TO_FILTER |
|
Pair<java.lang.Integer,java.lang.Iterable<PlanKey>> |
findPlanKeysFromAllOrphanedResultSummaries()
Scans database for all the ResultsSummary objects in the database that do not have a matching Plan |
|
|
findResultsSummaries(ResultsSummaryCriteria criteria)
Searches for ResultsSummary objects given a ResultsSummaryCriteria . |
|
|
getAllActiveResultSummariesForPlan(PlanKey planKey,
java.lang.Class<T> aClass)
Returns all the ResultsSummary in a LifeCycleState.PENDING , LifeCycleState.QUEUED , LifeCycleState.IN_PROGRESS state with the given Class
See also LifeCycleState.isActive(LifeCycleState) and ResultsSummary.isActive() |
|
|
getAllBuildResultSummariesInBuildState(BuildState state,
java.lang.Class<T> aClass)
Returns all the BuildResultsSummary in requested build state. |
|
|
getAllBuildResultSummariesInLifeCycleState(LifeCycleState state,
java.lang.Class<T> aClass)
Returns all the BuildResultsSummary in requested lifecycle state. |
|
|
getAllBuildResultSummariesInUnknownState(java.lang.Class<T> aClass)
Returns all the BuildResultsSummary in a BuildState.UNKNOWN
state
This will not return records marked for deletion. |
|
java.util.Collection<BuildResultsSummary> |
getAllInProgressBuildResultSummaries()
Returns all the BuildResultsSummary in a LifeCycleState.IN_PROGRESS state
This will not return records marked for deletion. |
|
|
getAllInProgressResultSummaries(java.lang.Class<T> aClass)
Returns all the ResultsSummary in a LifeCycleState.IN_PROGRESS state with the given Class
This will not return records marked for deletion. |
|
|
getAllPendingResultSummaries(java.lang.Class<T> aClass)
Returns all the ResultsSummary in a LifeCycleState.PENDING state with the given Class
This will not return records marked for deletion. |
|
|
getAllQueuedResultSummaries(java.lang.Class<T> aClass)
Returns all the ResultsSummary in a LifeCycleState.QUEUED state with the given Class
This will not return records marked for deletion. |
|
|
getAllResultSummariesForPlan(Plan plan)
Get all the ResultsSummary s for the given Plan |
|
ResultsSummary |
getBreakingBuild(ResultsSummary summary)
|
|
ChainStageResult |
getChainStageResultById(long id)
Returns a ChainStageResult by its id |
|
|
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)
Returns the first available BuildResultsSummary for the given Plan |
|
BuildResultsSummary |
getFirstBuildSummary(PlanKey planKey)
Returns the first available BuildResultsSummary for the given PlanKey |
|
ResultsSummary |
getFixingBuild(ResultsSummary summary)
Returns the first successful BuildResultsSummary for given BuildResultsSummary . |
|
java.util.List<LinkedJiraIssue> |
getJiraIssuesForBuild(Plan plan)
Retrieves a list of LinkedJiraIssue that are linked to the given build. |
|
java.util.List<LinkedJiraIssue> |
getJiraIssuesForBuildResults(java.util.List<ResultsSummary> buildResults)
Retrieves a list of LinkedJiraIssue linked to the given build result summaries |
|
|
getLastResultSummary(java.lang.String planKey,
java.lang.Class<T> aClass)
Returns the latest completed ResultsSummary for the plan represented by planKey |
|
java.util.List<ResultsSummary> |
getNeighbouringSummaries(ImmutablePlan plan,
int currentBuildNumber,
int neighbouringSummariesMaxCount)
Returns build results "around" given build number |
|
java.util.List<ResultsSummary> |
getNeighbouringSummaries(Plan plan,
int currentBuildNumber)
Returns build results "around" given build number |
|
int |
getNumberOfConcurrentlyRunningBuilds(PlanKey planKey)
Get the number of concurrently running builds for planKey |
|
long |
getNumberOfFinalizedResults(Plan plan)
Get number of the ResultsSummary s or LifeCycleState.NOT_BUILT state for the given Plan |
|
long |
getNumberOfFinishedResults(Plan plan)
Returns the number of finished results available for the given Plan |
|
ChainResultsSummary |
getParentResultSummary(ResultsSummary summary)
Get (@link ChainResultsSummary} containing given ResultsSummary |
|
|
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, all lazy initialized collections can be eagerly read |
|
java.lang.Long |
getResultsSummaryId(PlanResultKey planResultKey)
Return ResultsSummary 's database id. |
|
|
getResultSummariesByChangeSetId(java.lang.String changeSetId,
java.lang.Class<T> discriminator)
Get a list of all build results containing a commit with the given change set ID. |
|
|
getResultSummariesForPlan(ImmutablePlan plan,
int firstResult,
int maxResults)
Get the ResultsSummary s for the given Plan . |
|
|
getResultSummariesForPlanByLifeCycleState(Plan plan,
LifeCycleState lifeCycleState,
int firstResult,
int maxResults)
Get the ResultsSummary s for the given Plan in give LifeCycleState that are Results are
sorted by build number (descending). |
|
ChainStageResult |
getStageForResult(ResultsSummary summary)
Get (@link ChainStageResult} containing given ResultsSummary |
|
int |
markResultSummariesForDeletion(PlanKey planKey)
Mass update of all ResultsSummary records in the database related to a Plan identified by planKey. |
|
int |
removeResultsSummariesForPlan(PlanKey planKey)
Remove all resultSummary objects for the given plan. |
|
void |
removeResultsSummary(ResultsSummary resultsSummary)
Removes the passed result summary |
|
long |
scrollJiraIssuesForExport(com.google.common.base.Function<LinkedJiraIssue,java.lang.Void> function)
Scroll through and execute function for each of LinkedJiraIssue Objects passed to function are not fully initialized. |
|
long |
scrollResultSummaries(java.lang.String buildKey,
ResultDataRead dataRead,
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 |
scrollVariableSubstitutionForExport(com.google.common.base.Function<VariableSubstitution,java.lang.Void> function)
Scroll through and execute function for each of VariableSubstitution Objects passed to function are not fully initialized. |
|
void |
setPlanDiscriminatorRegistry(PlanDiscriminatorRegistry planDiscriminatorRegistry)
|
|
void |
setResultsSummaryDiscriminatorRegistry(ResultsSummaryDiscriminatorRegistry resultsSummaryDiscriminatorRegistry)
|
|
void |
setTestResultsHibernateDao(TestResultsHibernateDao testResultsHibernateDao)
|
Methods inherited from class com.atlassian.bamboo.persistence3.BambooHibernateObjectDao |
---|
delete, deleteAll, executeFind, executeReturnLong, findAll, save, saveAll |
Methods inherited from class org.springframework.orm.hibernate.support.HibernateDaoSupport |
---|
checkDaoConfig, convertHibernateAccessException, createHibernateTemplate, getHibernateTemplate, getSession, getSession, getSessionFactory, releaseSession, setHibernateTemplate, setSessionFactory |
Methods inherited from class org.springframework.dao.support.DaoSupport |
---|
afterPropertiesSet, initDao |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.atlassian.bamboo.persistence3.BambooObjectDao |
---|
delete, deleteAll, executeReturnLong, findAll, save, saveAll |
Field Detail |
---|
protected static final java.lang.String CREATION_DATE
protected static final java.lang.String BUILD_COMPLETED_DATE
protected static final java.lang.String BUILD_AGENT_ID
protected static final java.lang.String BUILD_NUMBER
protected static final java.lang.String PLAN_KEY
protected static final java.lang.String BUILD_STATE
protected static final java.lang.String LIFE_CYCLE_STATE
protected static final java.lang.String DELTA_STATE
Constructor Detail |
---|
public BuildResultsSummaryHibernateDao()
Method Detail |
---|
public java.lang.Long getResultsSummaryId(@NotNull PlanResultKey planResultKey)
BuildResultsSummaryDao
ResultsSummary
's database id.
This method is intended for internal use (currently in importer)
getResultsSummaryId
in interface BuildResultsSummaryDao
planResultKey
- plan result key of ResultsSummary
to be found
ResultsSummary
or null if not found@Nullable public <T extends ResultsSummary> T getResultsSummary(@NotNull PlanResultKey planResultKey, @NotNull java.lang.Class<T> aClass)
BuildResultsSummaryDao
ResultsSummary
by PlanResultKey
and expected type
getResultsSummary
in interface BuildResultsSummaryDao
@Nullable public <T extends ResultsSummary> T getResultsSummary(@NotNull PlanResultKey planResultKey, @NotNull java.lang.Class<T> aClass, ResultDataRead dataRead)
BuildResultsSummaryDao
ResultsSummary
by PlanResultKey
and expected type, all lazy initialized collections can be eagerly read
getResultsSummary
in interface BuildResultsSummaryDao
public <E extends ResultsSummary> E findById(long id, @NotNull java.lang.Class<E> aClass)
BambooObjectDao
findById
in interface BambooObjectDao<ResultsSummary>
findById
in class BambooHibernateObjectDao<ResultsSummary>
id
- id of entityaClass
- class of entity
@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllBuildResultSummariesInBuildState(@NotNull BuildState state, @NotNull java.lang.Class<T> aClass)
BuildResultsSummaryDao
BuildResultsSummary
in requested build state.
This will not return records marked for deletion.
getAllBuildResultSummariesInBuildState
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllBuildResultSummariesInLifeCycleState(@NotNull LifeCycleState state, @NotNull java.lang.Class<T> aClass)
BuildResultsSummaryDao
BuildResultsSummary
in requested lifecycle state.
This will not return records marked for deletion.
getAllBuildResultSummariesInLifeCycleState
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllBuildResultSummariesInUnknownState(java.lang.Class<T> aClass)
BuildResultsSummaryDao
BuildResultsSummary
in a BuildState.UNKNOWN
state
This will not return records marked for deletion.
getAllBuildResultSummariesInUnknownState
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllPendingResultSummaries(java.lang.Class<T> aClass)
BuildResultsSummaryDao
ResultsSummary
in a LifeCycleState.PENDING
state with the given Class
This will not return records marked for deletion.
getAllPendingResultSummaries
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllQueuedResultSummaries(java.lang.Class<T> aClass)
BuildResultsSummaryDao
ResultsSummary
in a LifeCycleState.QUEUED
state with the given Class
This will not return records marked for deletion.
getAllQueuedResultSummaries
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllInProgressResultSummaries(java.lang.Class<T> aClass)
BuildResultsSummaryDao
ResultsSummary
in a LifeCycleState.IN_PROGRESS
state with the given Class
This will not return records marked for deletion.
getAllInProgressResultSummaries
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.Collection<T> getAllActiveResultSummariesForPlan(PlanKey planKey, java.lang.Class<T> aClass)
BuildResultsSummaryDao
ResultsSummary
in a LifeCycleState.PENDING
, LifeCycleState.QUEUED
, LifeCycleState.IN_PROGRESS
state with the given Class
See also LifeCycleState.isActive(LifeCycleState)
and ResultsSummary.isActive()
getAllActiveResultSummariesForPlan
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.List<T> getFinalizedResultSummariesForPlan(PlanKey planKey, java.lang.Class<T> aClass, int firstResult, int maxResults)
BuildResultsSummaryDao
ResultsSummary
in a LifeCycleState.FINISHED
or LifeCycleState.NOT_BUILT
state with the given Class
.
Result are sorted descending by build number.
getFinalizedResultSummariesForPlan
in interface BuildResultsSummaryDao
firstResult
- - 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)
BuildResultsSummaryDao
getNumberOfConcurrentlyRunningBuilds
in interface BuildResultsSummaryDao
@NotNull public java.util.Collection<BuildResultsSummary> getAllInProgressBuildResultSummaries()
BuildResultsSummaryDao
BuildResultsSummary
in a LifeCycleState.IN_PROGRESS
state
This will not return records marked for deletion.
getAllInProgressBuildResultSummaries
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.List<T> findResultsSummaries(@NotNull ResultsSummaryCriteria criteria)
BuildResultsSummaryDao
ResultsSummary
objects given a ResultsSummaryCriteria
.
Note that if criteria does not specify maxResults property, a hard cap of 10000 results is applied to search operation.
findResultsSummaries
in interface BuildResultsSummaryDao
criteria
- @NotNull
List
of BuildResultsSummary
public int removeResultsSummariesForPlan(@NotNull PlanKey planKey)
BuildResultsSummaryDao
ResultsSummary
objects to be deleted
in such case #scheduleResultsSummariesForDelayedDeletion(PlanKey)
should be considered.
removeResultsSummariesForPlan
in interface BuildResultsSummaryDao
planKey
- identifier of plan to remove results for.
ResultsSummary
objectspublic Pair<java.lang.Integer,java.lang.Iterable<PlanKey>> findPlanKeysFromAllOrphanedResultSummaries()
BuildResultsSummaryDao
ResultsSummary
objects in the database that do not have a matching Plan
findPlanKeysFromAllOrphanedResultSummaries
in interface BuildResultsSummaryDao
ResultsSummary
s and list of distinct PlanKey
s they reference.public int countBuildResultsSummaries(long agentId, @Nullable BuildState buildState)
BuildResultsSummaryDao
countBuildResultsSummaries
in interface BuildResultsSummaryDao
buildState
- - can be null.
public int countBuildResultsSummaries(@NotNull java.lang.String planKey)
countBuildResultsSummaries
in interface BuildResultsSummaryDao
public int countBuildResultsSummaries()
BuildResultsSummaryDao
countBuildResultsSummaries
in interface BuildResultsSummaryDao
@NotNull public java.util.List<BuildResultsSummary> findBuildsForImageConfiguration(java.lang.String planKey, ElasticImageConfiguration elasticImage, @Nullable BuildState buildState, int maxResults)
BuildResultsSummaryDao
findBuildsForImageConfiguration
in interface BuildResultsSummaryDao
buildState
- @Nullable
public java.util.List<Pair<ArtifactLink,BuildResultsSummary>> findBuildResultsWithArtifacts(java.lang.String planKey)
BuildResultsSummaryDao
findBuildResultsWithArtifacts
in interface BuildResultsSummaryDao
public <T extends ResultsSummary> java.util.List<ResultWithPlanInfo<T>> getResultSummariesByChangeSetId(@NotNull java.lang.String changeSetId, java.lang.Class<T> discriminator)
BuildResultsSummaryDao
getResultSummariesByChangeSetId
in interface BuildResultsSummaryDao
changeSetId
- of the commitdiscriminator
- class of the ResultSummary interface required
@NotNull public java.util.List<ResultsSummary> findBuildResultsSummariesByJiraIssues(@Nullable java.util.List<java.lang.String> issueKeys)
BuildResultsSummaryDao
findBuildResultsSummariesByJiraIssues
in interface BuildResultsSummaryDao
@NotNull public java.util.List<ResultsSummary> findBuildResultsSummariesByProjectKey(@Nullable java.lang.String jiraProjectKey)
BuildResultsSummaryDao
findBuildResultsSummariesByProjectKey
in interface BuildResultsSummaryDao
jiraProjectKey
- - JIRA project key (prefix of the jira issues e.g. 'BAM')
public void removeResultsSummary(@NotNull ResultsSummary resultsSummary)
BuildResultsSummaryDao
removeResultsSummary
in interface BuildResultsSummaryDao
resultsSummary
- - @NotNull@Nullable public BuildResultsSummary getFirstBuildSummary(@NotNull Plan plan)
BuildResultsSummaryDao
BuildResultsSummary
for the given Plan
getFirstBuildSummary
in interface BuildResultsSummaryDao
public BuildResultsSummary getFirstBuildSummary(@NotNull PlanKey planKey)
BuildResultsSummaryDao
BuildResultsSummary
for the given PlanKey
getFirstBuildSummary
in interface BuildResultsSummaryDao
public <T extends ResultsSummary> T getLastResultSummary(java.lang.String planKey, java.lang.Class<T> aClass)
BuildResultsSummaryDao
ResultsSummary
for the plan represented by planKey
getLastResultSummary
in interface BuildResultsSummaryDao
public java.lang.Integer findFirstBuildNumberAfter(@NotNull java.lang.String planKey, int buildNumber)
BuildResultsSummaryDao
findFirstBuildNumberAfter
in interface BuildResultsSummaryDao
public java.lang.Integer findLastBuildNumberBefore(@NotNull java.lang.String planKey, int buildNumber)
BuildResultsSummaryDao
findLastBuildNumberBefore
in interface BuildResultsSummaryDao
public long getNumberOfFinishedResults(Plan plan)
BuildResultsSummaryDao
Plan
getNumberOfFinishedResults
in interface BuildResultsSummaryDao
public long getNumberOfFinalizedResults(@NotNull Plan plan)
ResultsSummary
s or LifeCycleState.NOT_BUILT
state for the given Plan
getNumberOfFinalizedResults
in interface BuildResultsSummaryDao
plan
-
@NotNull public java.util.List<ResultsSummary> getNeighbouringSummaries(Plan plan, int currentBuildNumber)
BuildResultsSummaryDao
getNeighbouringSummaries
in interface BuildResultsSummaryDao
@NotNull public java.util.List<ResultsSummary> getNeighbouringSummaries(ImmutablePlan plan, int currentBuildNumber, int neighbouringSummariesMaxCount)
BuildResultsSummaryDao
getNeighbouringSummaries
in interface BuildResultsSummaryDao
@Nullable public ResultsSummary getBreakingBuild(ResultsSummary summary)
getBreakingBuild
in interface BuildResultsSummaryDao
@Nullable public ResultsSummary getFixingBuild(ResultsSummary summary)
BuildResultsSummaryDao
BuildResultsSummary
for given BuildResultsSummary
.
The input build is returned if it is successful.
getFixingBuild
in interface BuildResultsSummaryDao
@NotNull public java.util.List<LinkedJiraIssue> getJiraIssuesForBuildResults(@NotNull java.util.List<ResultsSummary> buildResults)
BuildResultsSummaryDao
LinkedJiraIssue
linked to the given build result summaries
getJiraIssuesForBuildResults
in interface BuildResultsSummaryDao
@NotNull public java.util.List<LinkedJiraIssue> getJiraIssuesForBuild(@NotNull Plan plan)
BuildResultsSummaryDao
LinkedJiraIssue
that are linked to the given build.
getJiraIssuesForBuild
in interface BuildResultsSummaryDao
public long scrollJiraIssuesForExport(@NotNull com.google.common.base.Function<LinkedJiraIssue,java.lang.Void> function)
BuildResultsSummaryDao
scrollJiraIssuesForExport
in interface BuildResultsSummaryDao
function
- function to be executed on each of the LinkedJiraIssue
public long scrollVariableSubstitutionForExport(@NotNull com.google.common.base.Function<VariableSubstitution,java.lang.Void> function)
BuildResultsSummaryDao
scrollVariableSubstitutionForExport
in interface BuildResultsSummaryDao
function
- function to be executed on each of the VariableSubstitution
@Nullable public <T extends ResultsSummary> T findFirstResultAfter(@NotNull java.lang.String planKey, int buildNumber, java.lang.Class<T> aClass)
BuildResultsSummaryDao
BuildResultsSummary
after buildNumber
findFirstResultAfter
in interface BuildResultsSummaryDao
@Nullable public <T extends ResultsSummary> T findLastResultBefore(@NotNull java.lang.String planKey, int buildNumber, java.lang.Class<T> aClass)
BuildResultsSummaryDao
ResultsSummary
before buildNumber
findLastResultBefore
in interface BuildResultsSummaryDao
public <T extends ResultsSummary> T findLastBuildResultBeforeWithTests(@NotNull PlanResultKey planResultKey, @NotNull java.lang.Class<T> aClass)
findLastBuildResultBeforeWithTests
in interface BuildResultsSummaryDao
T
- of resultplanResultKey
- of the resultaClass
- of
public ResultsSummary findFirstBuildResultWithBuildStateAfter(@NotNull java.lang.String planKey, int buildNumber, @NotNull BuildState buildState)
BuildResultsSummaryDao
BuildResultsSummary
after buildNumber
findFirstBuildResultWithBuildStateAfter
in interface BuildResultsSummaryDao
public ResultsSummary findLastBuildResultWithBuildStateBefore(@NotNull java.lang.String planKey, int buildNumber, @NotNull BuildState buildState)
BuildResultsSummaryDao
BuildResultsSummary
before buildNumber with BuildState
findLastBuildResultWithBuildStateBefore
in interface BuildResultsSummaryDao
@Nullable public ResultsSummary findFirstBuildResultWithBuildStateBetween(@NotNull java.lang.String planKey, int lowerBuildNumber, int upperBuildNumber, @NotNull BuildState buildState)
BuildResultsSummaryDao
BuildState
between the given build number range
Note that this function is inclusive of the upper and lower bound
findFirstBuildResultWithBuildStateBetween
in interface BuildResultsSummaryDao
public long scrollResultSummaries(@NotNull java.lang.String buildKey, @NotNull ResultDataRead dataRead, @NotNull com.google.common.base.Function<ResultsSummary,java.lang.Void> function)
BuildResultsSummaryDao
scrollResultSummaries
in interface BuildResultsSummaryDao
buildKey
- of the plan you want to scroll the result summaries fordataRead
- if the data should be loaded lazy or eagerlyfunction
- function to be executed on each of the BuildResultSummary
public ChainStageResult getChainStageResultById(long id)
BuildResultsSummaryDao
ChainStageResult
by its id
getChainStageResultById
in interface BuildResultsSummaryDao
public <T extends ResultsSummary> java.util.List<T> getAllResultSummariesForPlan(@NotNull Plan plan)
BuildResultsSummaryDao
ResultsSummary
s for the given Plan
getAllResultSummariesForPlan
in interface BuildResultsSummaryDao
@NotNull public <T extends ResultsSummary> java.util.List<T> getResultSummariesForPlan(@NotNull ImmutablePlan plan, int firstResult, int maxResults)
BuildResultsSummaryDao
ResultsSummary
s for the given Plan
. Results are sorted by build number (descending). User can skip
first n result and request maximum number of results. Note: fetching huge amount of data in single call should be avoided.
getResultSummariesForPlan
in interface BuildResultsSummaryDao
firstResult
- 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> getResultSummariesForPlanByLifeCycleState(@NotNull Plan plan, @NotNull LifeCycleState lifeCycleState, int firstResult, int maxResults)
BuildResultsSummaryDao
ResultsSummary
s 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 BuildResultsSummaryDao
firstResult
- 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 ChainResultsSummary getParentResultSummary(ResultsSummary summary)
BuildResultsSummaryDao
ResultsSummary
getParentResultSummary
in interface BuildResultsSummaryDao
@Nullable public ChainStageResult getStageForResult(ResultsSummary summary)
BuildResultsSummaryDao
ResultsSummary
getStageForResult
in interface BuildResultsSummaryDao
public java.util.List<ResultsSummary> findLatestResultsSummaries()
BuildResultsSummaryDao
findLatestResultsSummaries
in interface BuildResultsSummaryDao
public java.util.List<ResultsSummary> findLatestFailedResultSummaries()
BuildResultsSummaryDao
findLatestFailedResultSummaries
in interface BuildResultsSummaryDao
public java.util.List<ChainResultsSummary> findChainResultsWithJobLabelled(ResultsSummaryCriteria queryCriteria, java.util.List<Label> labels)
BuildResultsSummaryDao
findChainResultsWithJobLabelled
in interface BuildResultsSummaryDao
queryCriteria
- containing the restrictions for the chains to be returnedlabels
- that the jobs can be associated with
public <T extends ResultsSummary> T findLastResultSummaryWithState(@NotNull PlanKey planKey, @NotNull BuildState buildState, @NotNull java.lang.Class<T> aClass)
findLastResultSummaryWithState
in interface BuildResultsSummaryDao
ResultsSummary
with the provided BuildState
public int countResultsWithState(@NotNull PlanKey planKey, int lowerBuildNumber, int upperBuildNumber, @NotNull BuildState buildState)
BuildResultsSummaryDao
countResultsWithState
in interface BuildResultsSummaryDao
planKey
- 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
public int markResultSummariesForDeletion(@NotNull PlanKey planKey)
BuildResultsSummaryDao
ResultsSummary
records in the database related to a Plan identified by planKey.
markResultSummariesForDeletion
in interface BuildResultsSummaryDao
planKey
- key of a plan
public void setResultsSummaryDiscriminatorRegistry(ResultsSummaryDiscriminatorRegistry resultsSummaryDiscriminatorRegistry)
public void setPlanDiscriminatorRegistry(PlanDiscriminatorRegistry planDiscriminatorRegistry)
public void setTestResultsHibernateDao(TestResultsHibernateDao testResultsHibernateDao)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |