|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
@ExperimentalApi @Internal public interface ImmutablePlanCacheService
An experimental API for getting immutable, weakly held, cached ImmutableChain
. This Service does not
check for permissions currently. Only works for Chain
.
Cache is disabled by default and should be explicitly enabled by application (preferably by calling initialiseCache()
)
Concepts:
CachedPlanManager
instead.
In 3.4, only used for Dashboard Cache
Nested Class Summary | |
---|---|
static interface |
ImmutablePlanCacheService.CacheInvalidator
|
Method Summary | ||
---|---|---|
void |
cascadeInvalidate(long planId)
Removes the cached reference for the passed plan and its children. |
|
void |
cascadeInvalidate(PlanKey planKey)
Removes the cached reference for the passed plan and its children. |
|
void |
disableCache()
Disable cache. |
|
void |
enableCache()
Enable cache. |
|
int[] |
getBuildNumberOverrides(PlanKey planKey)
Deprecated. since 4.4 |
|
BambooCacheStats |
getCacheStats()
Retrieve cache statistics |
|
Iterable<PlanKey> |
getChainsToInvalidate(ImmutablePlanCacheService.CacheInvalidator invalidator)
Internal. |
|
ImmutableChain |
getImmutablePlanByKey(PlanKey planKey)
Returns a plan if one exists with the key. |
|
PlanCacheIndices |
getIndices()
Returns the indices created for plan cache content. |
|
ReentrantReadWriteLock |
getLock(PlanKey planKey)
Makes plan inaccessible |
|
PlanIdentifier |
getPlanIdentifierForPermissionCheckingByKey(PlanKey planKey)
Deprecated. since 5.4 use CachedPlanManager.getPlanByKey(com.atlassian.bamboo.plan.PlanKey) |
|
|
getPlans(Class<T> planType)
Returns all Plan 's filtered by Class . |
|
|
getPlans(Class<T> planType,
com.google.common.base.Predicate<? super T> filter)
Returns all Plan 's filtered by Class . |
|
void |
initialiseCache()
Clear the cache and attempt to read all Chains from DB in order to cache them. |
|
void |
invalidate(PlanKey planKey)
Removes the cached Plan. |
|
void |
reset(PlanKey planKey)
Removes the cached Plan and its metadata. |
|
void |
resetAll()
Nukes the cache |
|
void |
setBuildNumberOverrides(PlanKey planKey,
int firstBuildNumber,
int lastBuildNumber,
int nextBuildNumber)
Deprecated. since 4.4 |
Method Detail |
---|
@Nullable ImmutableChain getImmutablePlanByKey(@NotNull PlanKey planKey)
planKey
-
@NotNull <T extends ImmutablePlan> List<T> getPlans(Class<T> planType)
Plan
's filtered by Class
. Does not include plans marked for deletion.
planType
- - the type of the plan to retrieve
DescriptionProvider.getName()
@NotNull <T extends ImmutablePlan> List<T> getPlans(Class<T> planType, @NotNull com.google.common.base.Predicate<? super T> filter)
Plan
's filtered by Class
. Does not include plans marked for deletion.
planType
- - the type of the plan to retrieve
DescriptionProvider.getName()
@Nullable @Deprecated PlanIdentifier getPlanIdentifierForPermissionCheckingByKey(@NotNull PlanKey planKey)
CachedPlanManager.getPlanByKey(com.atlassian.bamboo.plan.PlanKey)
ReentrantReadWriteLock getLock(@NotNull PlanKey planKey)
planKey
- key of the Plan to be made inaccessiblevoid invalidate(@NotNull PlanKey planKey)
planKey
- key of the Plan to be removed from cachevoid cascadeInvalidate(@NotNull PlanKey planKey)
planKey
- key of the Plan to be removed from cachevoid cascadeInvalidate(long planId)
planId
- void reset(@NotNull PlanKey planKey)
planKey
- key of the Plan to be removed from cachevoid resetAll()
void initialiseCache()
void disableCache()
void enableCache()
initialiseCache()
instead if you expect plans to be loaded.
BambooCacheStats getCacheStats()
@Deprecated @Internal void setBuildNumberOverrides(PlanKey planKey, int firstBuildNumber, int lastBuildNumber, int nextBuildNumber)
@Deprecated @Internal @Nullable int[] getBuildNumberOverrides(PlanKey planKey)
@Internal @NotNull Iterable<PlanKey> getChainsToInvalidate(@NotNull ImmutablePlanCacheService.CacheInvalidator invalidator)
ImmutablePlanCacheService.CacheInvalidator
invalidator
- @NotNull PlanCacheIndices getIndices()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |