@Component @Path(value="/snapshot") public class SnapshotResource extends Object
| Constructor and Description |
|---|
SnapshotResource(SnapshotJobManager jobManager,
SnapshotManager snapshotManager,
SnapshotRepo snapshotRepo,
SnapshotContentItemRepo snapshotContentItemRepo,
EventLog eventLog,
StoreClientHelper storeClientHelper) |
| Modifier and Type | Method and Description |
|---|---|
javax.ws.rs.core.Response |
cancel(String snapshotId) |
javax.ws.rs.core.Response |
complete(String snapshotId,
org.duracloud.snapshot.dto.bridge.CompleteSnapshotBridgeParameters params)
Notifies the bridge that the snapshot transfer from the bridge storage to
the preservation storage is complete.
|
javax.ws.rs.core.Response |
create(String snapshotId,
org.duracloud.snapshot.dto.bridge.CreateSnapshotBridgeParameters params) |
javax.ws.rs.core.Response |
error(String snapshotId,
org.duracloud.snapshot.dto.bridge.SnapshotErrorBridgeParameters params)
Notifies the bridge that the snapshot process is not able to continue
due to an error which cannot be resolved by the system processing the
snapshot data.
|
javax.ws.rs.core.Response |
getContent(String snapshotId,
Integer page,
Integer pageSize,
String prefix) |
javax.ws.rs.core.Response |
getHistory(String snapshotId,
Integer page,
Integer pageSize) |
javax.ws.rs.core.Response |
getSnapshot(String snapshotId) |
javax.ws.rs.core.Response |
list(String host,
String storeId,
org.duracloud.snapshot.dto.SnapshotStatus status)
Returns a list of snapshots.
|
protected List<Snapshot> |
listSnapshots(String host,
String storeId,
org.duracloud.snapshot.dto.SnapshotStatus status) |
javax.ws.rs.core.Response |
restart(String snapshotId) |
javax.ws.rs.core.Response |
updateHistory(String snapshotId,
org.duracloud.snapshot.dto.bridge.UpdateSnapshotHistoryBridgeParameters params)
Updates a snapshot's history
|
@Autowired public SnapshotResource(SnapshotJobManager jobManager, SnapshotManager snapshotManager, SnapshotRepo snapshotRepo, SnapshotContentItemRepo snapshotContentItemRepo, EventLog eventLog, StoreClientHelper storeClientHelper)
@GET
@Produces(value="application/json")
public javax.ws.rs.core.Response list(@QueryParam(value="host")
String host,
@QueryParam(value="storeId")
String storeId,
@QueryParam(value="status")
org.duracloud.snapshot.dto.SnapshotStatus status)
protected List<Snapshot> listSnapshots(String host, String storeId, org.duracloud.snapshot.dto.SnapshotStatus status)
@Path(value="{snapshotId}")
@GET
@Produces(value="application/json")
public javax.ws.rs.core.Response getSnapshot(@PathParam(value="snapshotId")
String snapshotId)
@Path(value="{snapshotId}/restart")
@POST
@Produces(value="application/json")
public javax.ws.rs.core.Response restart(@PathParam(value="snapshotId")
String snapshotId)
@Path(value="{snapshotId}/cancel")
@POST
@Produces(value="application/json")
public javax.ws.rs.core.Response cancel(@PathParam(value="snapshotId")
String snapshotId)
throws org.duracloud.snapshot.SnapshotException
org.duracloud.snapshot.SnapshotException@Path(value="{snapshotId}")
@PUT
@Consumes(value="application/json")
@Produces(value="application/json")
public javax.ws.rs.core.Response create(@PathParam(value="snapshotId")
String snapshotId,
org.duracloud.snapshot.dto.bridge.CreateSnapshotBridgeParameters params)
@Path(value="{snapshotId}/complete")
@POST
@Consumes(value="application/json")
@Produces(value="application/json")
public javax.ws.rs.core.Response complete(@PathParam(value="snapshotId")
String snapshotId,
org.duracloud.snapshot.dto.bridge.CompleteSnapshotBridgeParameters params)
snapshotId - params - @Path(value="{snapshotId}/error")
@POST
@Consumes(value="application/json")
@Produces(value="application/json")
public javax.ws.rs.core.Response error(@PathParam(value="snapshotId")
String snapshotId,
org.duracloud.snapshot.dto.bridge.SnapshotErrorBridgeParameters params)
snapshotId - params - @Path(value="{snapshotId}/content")
@GET
@Produces(value="application/json")
public javax.ws.rs.core.Response getContent(@PathParam(value="snapshotId")
String snapshotId,
@QueryParam(value="page")
Integer page,
@QueryParam(value="pageSize")
Integer pageSize,
@QueryParam(value="prefix")
String prefix)
@Path(value="{snapshotId}/history")
@GET
@Produces(value="application/json")
public javax.ws.rs.core.Response getHistory(@PathParam(value="snapshotId")
String snapshotId,
@QueryParam(value="page")
Integer page,
@QueryParam(value="pageSize")
Integer pageSize)
@Path(value="{snapshotId}/history")
@POST
@Consumes(value="application/json")
@Produces(value="application/json")
public javax.ws.rs.core.Response updateHistory(@PathParam(value="snapshotId")
String snapshotId,
org.duracloud.snapshot.dto.bridge.UpdateSnapshotHistoryBridgeParameters params)
snapshotId - - a snapshot's ID or it's alternate IDparams - - JSON object that contains the history String and a
Boolean of whether this request is using a snapshot's ID
or an alternate IDCopyright © 2014–2019 DuraSpace. All rights reserved.