Interface InternalResultsSummaryAccessor
- All Known Implementing Classes:
InternalResultsSummaryAccessorImpl
@Internal
public interface InternalResultsSummaryAccessor
Read-only accessor to result data.
The results returned by this bean are not filtered by permissions.
- Since:
- 10.0
-
Method Summary
Modifier and TypeMethodDescriptionfindBuildResultNumbersRange
(@NotNull PlanKey planKey) Finds minimum and maximum build number for a plan.long
getAveragePlanExecutionDuration
(@NotNull ImmutablePlan plan, int numberOfResults) Get average duration from n last results summaries in finished state for a plan.<T extends ResultsSummary>
TgetLastResultsSummary
(@NotNull PlanKey planKey, Class<T> aClass) Get the lastResultsSummary
for planKey andClass
<T extends ResultsSummary>
TgetLastResultsSummary
(@NotNull PlanKey planKey, Class<T> aClass, boolean ignoreSpecsResults) Get the lastResultsSummary
for planKey andClass
with possible skip of specs results.<T extends ResultsSummary>
TgetResultsSummary
(@NotNull PlanResultKey planResultKey, @NotNull Class<T> aClass) LookupResultsSummary
byPlanResultKey
and expected type<T extends ResultsSummary>
TgetResultsSummary
(@NotNull PlanResultKey planResultKey, @NotNull Class<T> aClass, ResultDataRead dataRead) Lookup the ResultsSummary byPlanResultKey
.@Nullable ResultsSummary
getResultsSummary
(@NotNull PlanResultKey planResultKey, ResultDataRead dataRead) Lookup the ResultsSummary byPlanResultKey
.@Nullable ResultsSummary
getResultsSummary
(PlanResultKey planResultKey) Lookup the ResultsSummary byPlanResultKey
-
Method Details
-
getLastResultsSummary
@Nullable <T extends ResultsSummary> T getLastResultsSummary(@NotNull @NotNull PlanKey planKey, Class<T> aClass) Get the lastResultsSummary
for planKey andClass
- Type Parameters:
T
-- Parameters:
planKey
-aClass
-- Returns:
-
getLastResultsSummary
@Nullable <T extends ResultsSummary> T getLastResultsSummary(@NotNull @NotNull PlanKey planKey, Class<T> aClass, boolean ignoreSpecsResults) Get the lastResultsSummary
for planKey andClass
with possible skip of specs results.- Type Parameters:
T
-- Parameters:
planKey
-aClass
-ignoreSpecsResults
-- Returns:
-
getResultsSummary
Lookup the ResultsSummary byPlanResultKey
- Parameters:
planResultKey
-- Returns:
- resultsSummary
-
getResultsSummary
@Nullable @Nullable ResultsSummary getResultsSummary(@NotNull @NotNull PlanResultKey planResultKey, ResultDataRead dataRead) Lookup the ResultsSummary byPlanResultKey
. All lazy initialized collections can be eagerly fetched to avoid session problems. Use with caution - expensive call- Parameters:
planResultKey
-dataRead
-- Returns:
- resultsSummary
-
getResultsSummary
@Nullable <T extends ResultsSummary> T getResultsSummary(@NotNull @NotNull PlanResultKey planResultKey, @NotNull @NotNull Class<T> aClass) LookupResultsSummary
byPlanResultKey
and expected type- Type Parameters:
T
-- Parameters:
planResultKey
-aClass
-- Returns:
- resultSummary
-
getResultsSummary
@Nullable <T extends ResultsSummary> T getResultsSummary(@NotNull @NotNull PlanResultKey planResultKey, @NotNull @NotNull Class<T> aClass, ResultDataRead dataRead) Lookup the ResultsSummary byPlanResultKey
. All lazy initialized collections can be eagerly fetched to avoid session problems. Use with caution - expensive call- Parameters:
planResultKey
-dataRead
-- Returns:
- resultsSummary
-
getAveragePlanExecutionDuration
Get average duration from n last results summaries in finished state for a plan. Results in SUCCESSFUL state are preferred; only if there are none those in FAILED state are selected.- Parameters:
plan
-numberOfResults
- amount of results to be taken into account for average calculation- Returns:
- average duration in milliseconds or 0 if there is no results
-
findBuildResultNumbersRange
Finds minimum and maximum build number for a plan. Works for both chains and jobs.- Parameters:
planKey
-- Returns:
- (min, max) pair or (0,0) if there are no results.
-