public class CachedBuildPersisterDecorator extends Object implements BuildPersisterDecorator
Constructor and Description |
---|
CachedBuildPersisterDecorator(BuildPersisterDecorator parent) |
Modifier and Type | Method and Description |
---|---|
void |
deleteBuildResults(PlanKey planKey,
long buildNumber)
Remove a specific build build
|
boolean |
isActive()
Indicates whether this is currently active.
|
@Nullable BuildResults |
loadBuildResults(Key planKey,
int buildNumber)
Cache the build results so that the least used results get purged
|
void |
saveBuildResults(PlanKey planKey,
BuildResults buildResults)
Simply pass this request onto the parent
|
void |
start()
Loads the cache from the parent decorator on startup;
|
void |
stop()
Stop the component and clean up any resources
|
public CachedBuildPersisterDecorator(BuildPersisterDecorator parent)
public void start() throws Exception
public void stop() throws Exception
Startable
public boolean isActive()
Startable
Indicates whether this is currently active.
public void deleteBuildResults(PlanKey planKey, long buildNumber) throws PersisterException
deleteBuildResults
in interface BuildPersisterDecorator
planKey
- buildNumber
- The build numberPersisterException
public void saveBuildResults(PlanKey planKey, BuildResults buildResults) throws PersisterException
saveBuildResults
in interface BuildPersisterDecorator
buildResults
- The build results to persistPersisterException
- when failed to persist the build results@Nullable public @Nullable BuildResults loadBuildResults(Key planKey, int buildNumber) throws PersisterException
loadBuildResults
in interface BuildPersisterDecorator
buildNumber
- The number of the build results we are interested inPersisterException
- when failed to load the build resultsCopyright © 2022 Atlassian Software Systems Pty Ltd. All rights reserved.