Last updated August 20, 2009 22:23, by Craig McClanahan
Feedicon  
<h1>Cloud API Specification - Requests to Snapshot Resources</h1> The requests documented in this section are directed to ''Snapshot'' resources, which represent a point-in-time backup of the contents of a Volume. __TOC__ = Get Snapshot = Retrieve information about a volume snapshot. '''Synopsis:''' GET {Snapshot URI} '''Request Headers:''' Accept, Authorization, X-Cloud-Client-Specification-Version. '''Request Parameters:''' N/A. '''Request Message Body:''' N/A. '''Response Headers:''' Content-Length, Content-Type. '''Response Message Body:''' Snapshot. '''Response Status:''' 200, 400, 401, 403. '''Example Request:''' Retrieve information about a named "backsnap". GET /snapshots/xxxxx Host: example.com Authorization: Basic xxxxxxxxxxxxxxxxxxx Accept: application/vnd.com.sun.cloud.Snapshot+json X-Cloud-Client-Specification-Version: 0.1 '''Example Response:''' HTTP/1.1 200 OK Content-Type: application/vnd.com.sun.cloud.Snapshot+json Content-Length: nnn { "name" : "backsnap", "uri" : "/snapshots/yyyyy", "created" : 12345, "clone" : "/create-clone/abc", "rollback" : /rollback/xyz" } = Update Snapshot Properties = There are no current snapshot properties that may be modified by the client, so this request type is not available. = Delete Snapshot = Delete this snapshot from the owning volume. '''Synopsis:''' DELETE { URI of Snapshot } '''Request Headers:''' Authorization, X-Cloud-Client-Specification-Version. '''Request Parameters:''' N/A. '''Request Message Body:''' N/A. '''Response Headers:''' Content-Length, Content-Type. '''Response Message Body:''' Status for use in tracking snapshot-deletion progress. '''Response Status:''' 202, 400, 401, 403, 404. '''Status "op" Value:''' "delete-Snapshot". '''Status "target_uri" identifies:''' The Snapshot being deleted. '''Example Request:''' Delete an existing snapshot named "backsnap" DELETE /snapshot/1234567890 Host: example.com Authorization: Basic xxxxxxxxxxxxxxxxxxx X-Cloud-Client-Specification-Version: 0.1 '''Example Response:''' HTTP/1.1 202 Accepted Content-Type: application/vnd.com.sun.cloud.Status+json Content-Length: nnn { "op": "delete-Snapshot", "progress": 100, "target_uri": /snapshot/1234567890", "status_uri": "/statuses?op=ds&target=1234567890", "status": 200 } = Create Clone = Create a new volume populated with initial content from this snapshot. '''Synopsis:''' POST { URI from clone link of containing Snapshot } '''Request Headers:''' Accept, Authorization, Content-Length, Content-Type, X-Compute-Client-Specification-Version. '''Request Parameters:''' N/A. '''Request Message Body:''' Volume. '''Response Headers:''' Content-Length, Content-Type. '''Response Message Body:''' Status for use in tracking clone creation progress. '''Response Status:''' 202, 400, 401, 403, 404. '''Status "op" Value:''' "clone-Snapshot". '''Status "target_uri" identifies:''' The new Volume once it is created. '''Example Request:''' Create a new volume named "restored_backups" from this snapshot named "backsnap" on a volume named "backups". POST /create-clone/xxx Host: example.com Authorization: Basic xxxxxxxxxxxxxxxxxxx Accept: application/vnd.com.sun.cloud.Volume+json Content-Length: nnn Content-Type: application/vnd.com.sun.cloud.Volume+json X-Cloud-Client-Specification-Version: 0.1 { "name" : "restored_backups" } '''Example Response:''' HTTP/1.1 202 Accepted Content-Type: application/vnd.com.sun.cloud.Status+json Content-Length: nnn { "op": "clone-Snapshot", "progress": 100, "target_uri": "/filesystems/foo", "status_uri": "/statuses?seq=efaa76r59327", "status": 201 } = Roll Back Volume To Snapshot = Roll the contents of the owning volume back to the contents as of the moment this snapshot was taken. No change occurs to the snapshot itself. '''Synopsis:''' POST { URI from rollback link of containing Snapshot } '''Request Headers:''' Accept, Authorization, Content-Length, Content-Type, X-Cloud-Client-Specification-Version. '''Request Parameters:''' N/A. '''Request Message Body:''' N/A. '''Response Headers:''' Content-Length, Content-Type. '''Response Message Body:''' Status for use in tracking rollback progress. '''Response Status:''' 202, 400, 401, 403, 404. '''Status "op" Value:''' "rollback-to-Snapshot". '''Status "target_uri" identifies:''' The snapshot receiving the request. '''Example Request:''' Roll the "backups" filesystem, which owns this snapshot, back to the state as of the moment this snapshot was taken. POST /roll-back/xxx Host: example.com Authorization: Basic xxxxxxxxxxxxxxxxxxx X-Cloud-Client-Specification-Version: 0.1 '''Example Response:''' HTTP/1.1 202 Accepted Content-Type: application/vnd.com.sun.cloud.Status+json Content-Length: nnn { "op": "rollback-to-Snapshot", "progress": 0, "target_uri": "/snapshots/SN03ax", "status_uri": "/statuses?seq=TThhaa983", } Copyright &copy; Sun Microsystems, 2009. This work is licensed under [http://creativecommons.org/licenses/by/3.0/ Creative Commons Attribution 3.0 Unported License]
  • Mysql
  • Glassfish
  • Jruby
  • Rails
  • Nblogo
Terms of Use; Privacy Policy;
© 2010, Oracle Corporation and/or its affiliates
(revision 20120518.3c65429)
 
 
Close
loading
Please Confirm
Close