Bridge Application
Table of Contents |
---|
Panel | ||||||
---|---|---|---|---|---|---|
| ||||||
Initialize
Version
|
Panel | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
Get Total Count of Snapshots
Get Total Size (bytes) of Snapshots
Get Total Files of Snapshots
Get All Totals (count, size, files) of Snapshots
|
Panel | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||
Create Snapshot
ListAllSnapshots
List Snapshot Contents
| ||||||||||||||||||||||
[
"snapshot1",
"snapshot2",
"snapshot3"
] |
{
"contentItems" : [
{ "contentId" : "",
"contentProperties" : {"" : ""}
}
]
} |
List Snapshot History
- Purpose: Retrieves a list of content items which were included in a snapshot
- Request:
GET https://host:port/bridge/snapshot/(snapshotId)/history ? page=(pageNumber) & pageSize=(pageSize)
- snapshotId - Identifier of the snapshot
- pageNumber - Page number of history set
- pageSize - Number of history items to return in a single response
- Response Body: JSON:
Code Block |
---|
{
"totalCount" : (Long) # of historyItems
"historyItems" : [
{ "historyDate" : (Long) epoch time,
"history" : "${history item string}"
},
]
} |
Get Snapshot Details
Snapshot Status- Purpose: Provides the status of a snapshot action
- Request:
GET https://host:port/bridge/snapshotssnapshot/(snapshotId)
- snapshotID snapshotId - Identifier of the snapshot
- Response Code: 200 (on success)
Response Body: JSON:
Code Block { "snapshotId" : "", "snapshotDate" : "", "status" : "", "sourceHost" : "", "sourceSpaceId" : "", "sourceStoreId" : "", "description" : "", "contentItemCount" : "", "totalSizeInBytes" : "" }
Possible values for status:
- ?
title | Restore Operations |
---|
INITIALIZED
TRANSFERRING_FROM_DURACLOUD
REPLICATING_TO_STORAGE
CLEANING_UP
SNAPSHOT_COMPLETE
FAILED_TO_TRANSFER_FROM_DURACLOUD
- ERROR
- CANCELLED
Snapshot Complete
- Purpose: Enables storage provider (Chronopolis) to notify bridge app that snapshot content has been successfully transferred to preservation storage and can now be removed from the bridge storage area (and DuraCloud)
- Request:
POST https://host:port/bridge/snapshot/(snapshotId)/complete
- snapshotId - Identifier of the snapshot
Request Body: JSON:
Code Block { "alternateIds": ["alternate-id-1", "alternate-id-2"] }
A Snapshot can be mapped to zero or more alternate identifiers (e.g. IDs for bags which contain the content in this snapshot).
- Response Code: 200 (on success)
Response Body: JSON:
Code Block { "status" : "SNAPSHOT_COMPLETE", "details" : "" }
Snapshot Error
- Purpose: Enables storage provider (Chronopolis) to notify bridge app that processing of the snapshot has resulted in an error
Restore Snapshot
- Purpose: Enables user to initiate the restoration of a snapshot
- Request:
POST https://host:port/bridge/
snapshotssnapshot/(
snapshotIDsnapshotId)/
restoreerror
- snapshotID snapshotId - Identifier of the snapshot
Request Body: JSON:
Code Block { "error": "" }
- Response Code: 200 (on success)
Response Body: JSON:
Code Block { "status" : "SNAPSHOT_ERROR", "details" : "" }
Restart Snapshot
- Purpose: Enables restart of snapshots that failed to transfer successfully from DuraCloud.
- Request:
POST https://host:port/bridge/snapshot/(snapshotId)/restart
- snapshotId - Identifier of the snapshot
Request Body: JSON:
Code Block {}
- Response Code: 202 (on success)
Response Body: JSON:
Code Block { "status" : "INITIALIZED", "description" : "" }
Cancel Snapshot
- Purpose: Enables cancellation of a snapshot that is underway. Calls to this method will fail if the snapshot is in the CLEANING_UP or COMPLETE states.
- Request:
POST https://host:port/bridge/snapshot/(snapshotId)/cancel
- snapshotId - Identifier of the snapshot
Request Body: JSON:
Code Block {}
- Response Code: 200 (on success)
Response Body: JSON:
Code Block { "status" : "CANCELLED", "description" : "" }
Snapshot History Update
- Purpose: Enables storage provider (Chronopolis) to notify bridge app that a snapshot has an "update" to its history. Whether a snapshot was replicated, successfully stored, checksumed, etc... this is the REST call to handle any and all updates to the history of a particular Snapshot.
- Request:
POST
https://host:port/bridge/snapshot/(identifier)/
history
- identifier - Either the snapshot ID or an alternate ID (such as a bag ID) which was associated with the snapshot in the Snapshot Complete call
Request Body: JSON:
- Parameters
- 'history' - single escaped JSON string that can contain a JSON array of objects or strings - the history event we're trying to record
- 'alternate' - whether the snapshot ID in the URL is the alternate ID or the original snapshot ID.
Preferred format (using name/value pairs)
Code Block {"history": "[ {'key1' : 'value1'},{'key2' : 'value2'} ]", "alternate": "false"}
Alternative formats (also supported, but UI display may not be ideal)
Code Block {"history": "[ 'value1', 'value2' ]", "alternate": "false"} OR {"history": "[ {'key1': 'value1'}, 'value2' ]", "alternate": "false"} OR {"history": "value1", "alternate": "false"}
- Parameters
- Response Code: 200 (on success)
Response Body: JSON:
Code Block { "snapshot" : {SnapshotSummary}, "history" : "${the history string that was just inserted}" }
Panel | |||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||
Request Snapshot Restore
Restore Complete
Restore Snapshot
Restore Complete
Get Restore Details
Restart Restore
Cancel Restore
|