Class XStreamBuildPersister
java.lang.Object
com.atlassian.bamboo.persister.file.XStreamBuildPersister
- All Implemented Interfaces:
Startable,BuildPersisterDecorator
This class provides an XStream implementation of the Bamboo
BuildPersisterDecorator'er.-
Constructor Summary
ConstructorsConstructorDescriptionXStreamBuildPersister(StorageLocationService storageLocationService, XStreamFactory xStreamFactory) -
Method Summary
Modifier and TypeMethodDescriptionvoiddeleteBuildResults(PlanKey planKey, long buildNumber) Remove the build files for the given build buildNumber.booleanisActive()Indicates whether this is currently active.@Nullable BuildResultsloadBuildResults(Key planKey, int buildNumber) Load the build buildresults for the given build numbervoidsaveBuildResults(PlanKey planKey, BuildResults buildResults) Save the build resultsvoidstart()Load the build data file map.voidstop()Do nothing!
-
Constructor Details
-
XStreamBuildPersister
public XStreamBuildPersister(StorageLocationService storageLocationService, XStreamFactory xStreamFactory)
-
-
Method Details
-
start
public void start()Load the build data file map. -
stop
public void stop()Do nothing! -
isActive
public boolean isActive()Description copied from interface:StartableIndicates whether this is currently active.
-
saveBuildResults
Save the build results- Specified by:
saveBuildResultsin interfaceBuildPersisterDecorator- Parameters:
planKey-buildResults- The results to save @throws PersisterException An error- Throws:
PersisterException- when failed to persist the build results
-
loadBuildResults
@Nullable public @Nullable BuildResults loadBuildResults(Key planKey, int buildNumber) throws PersisterException Load the build buildresults for the given build number- Specified by:
loadBuildResultsin interfaceBuildPersisterDecorator- Parameters:
planKey-buildNumber- The build top load- Returns:
- The build results
- Throws:
PersisterException- An error
-
deleteBuildResults
Remove the build files for the given build buildNumber.- Specified by:
deleteBuildResultsin interfaceBuildPersisterDecorator- Parameters:
planKey-buildNumber- The number of the build to delete @throws PersisterException A generic failure- Throws:
PersisterException
-