Class SpaceModifyingSnapshotTaskRunner
- java.lang.Object
-
- org.duracloud.snapshottask.snapshot.AbstractSnapshotTaskRunner
-
- org.duracloud.snapshottask.snapshot.SpaceModifyingSnapshotTaskRunner
-
- All Implemented Interfaces:
TaskRunner
- Direct Known Subclasses:
CompleteCancelSnapshotTaskRunner,CreateSnapshotTaskRunner
public abstract class SpaceModifyingSnapshotTaskRunner extends AbstractSnapshotTaskRunner
-
-
Constructor Summary
Constructors Constructor Description SpaceModifyingSnapshotTaskRunner(StorageProvider snapshotProvider, SnapshotStorageProvider unwrappedSnapshotProvider, String dcSnapshotUser, String bridgeAppHost, String bridgeAppPort, String bridgeAppUser, String bridgeAppPass)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddSnapshotIdToSpaceProps(String spaceId, String snapshotId)protected StringgetSnapshotIdFromProperties(String spaceId)Returns snapshot from the snapshot properties file if it existsprotected StringgetSnapshotUser()protected StorageProvidergetStorageProvider()protected voidremoveSnapshotIdFromSpaceProps(String spaceId)protected voidremoveSnapshotProps(String spaceId)protected StringremoveSnapshotUserPermissions(String spaceId)protected StringsetSnapshotUserPermissions(String spaceId)protected booleansnapshotPropsPresentInSpace(String spaceId)Checks if the snapshot props file is in the space.protected voidstoreSnapshotProps(String spaceId, String serializedProps)Stores a set of snapshot properties in the given space as a properties file.-
Methods inherited from class org.duracloud.snapshottask.snapshot.AbstractSnapshotTaskRunner
buildBridgeBaseURL, createRestHelper, getBridgeAppHost, getBridgeAppPass, getBridgeAppPort, getBridgeAppUser, getMessageValue, getValueFromJson, jsonStringToMap
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.duracloud.storage.provider.TaskRunner
getName, performTask
-
-
-
-
Constructor Detail
-
SpaceModifyingSnapshotTaskRunner
public SpaceModifyingSnapshotTaskRunner(StorageProvider snapshotProvider, SnapshotStorageProvider unwrappedSnapshotProvider, String dcSnapshotUser, String bridgeAppHost, String bridgeAppPort, String bridgeAppUser, String bridgeAppPass)
-
-
Method Detail
-
getStorageProvider
protected StorageProvider getStorageProvider()
-
getSnapshotUser
protected String getSnapshotUser()
-
addSnapshotIdToSpaceProps
protected void addSnapshotIdToSpaceProps(String spaceId, String snapshotId)
-
storeSnapshotProps
protected void storeSnapshotProps(String spaceId, String serializedProps)
Stores a set of snapshot properties in the given space as a properties file.- Parameters:
spaceId- the space in which the properties file should be storedserializedProps- properties in serialized format
-
getSnapshotIdFromProperties
protected String getSnapshotIdFromProperties(String spaceId)
Returns snapshot from the snapshot properties file if it exists- Parameters:
spaceId-- Returns:
- snapshot from the snapshot properties file if it exists, otherwise null
-
removeSnapshotIdFromSpaceProps
protected void removeSnapshotIdFromSpaceProps(String spaceId)
-
removeSnapshotProps
protected void removeSnapshotProps(String spaceId)
-
snapshotPropsPresentInSpace
protected boolean snapshotPropsPresentInSpace(String spaceId)
Checks if the snapshot props file is in the space.- Parameters:
spaceId-- Returns:
-
-