summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorvenkata edara <redara@redhat.com>2017-04-04 15:52:53 +0530
committerPrashanth Pai <ppai@redhat.com>2017-04-04 09:27:23 -0400
commite9c2c5eb55e1012ccce0ce51ac48bed0c0f1d4b7 (patch)
tree24bb2feb0c3aa81751625e84163f75586cdcbafb /doc
parentc1c39697d8866cc7437da8fdfd2b08fd8cb54690 (diff)
Add support for S3 Multipart Upload API
Obj server checks if +segments is there and creates directory to support multi-part upload Updated s3.md to show usage of multi-part upload. Change-Id: I1e8a0dd850f51b2cc5dd2147607e46978dc2f936 Signed-off-by: venkata edara <redara@redhat.com> Reviewed-on: https://review.gluster.org/16983 Reviewed-by: Prashanth Pai <ppai@redhat.com> Tested-by: Prashanth Pai <ppai@redhat.com>
Diffstat (limited to 'doc')
-rw-r--r--doc/markdown/s3.md46
1 files changed, 46 insertions, 0 deletions
diff --git a/doc/markdown/s3.md b/doc/markdown/s3.md
index 75a9954..086718e 100644
--- a/doc/markdown/s3.md
+++ b/doc/markdown/s3.md
@@ -74,6 +74,52 @@ These examples assume you have an account (GlusterFS volume) named `test` and an
```sh
./s3curl.pl --id 'test:tester' --key 'testing' --del -- -k -v -s http://localhost:8080/bucket1
```
+**Multi-part upload an object to the bucket**
+
+ ***a. Initiate multi part***
+```sh
+./s3curl.pl --id 'test:tester' --key 'testing' --post -- "http://localhost:8080/bucket/mobject?uploads"
+```
+
+***b.upload the multi parts***
+upload all the parts by changing partNumber. get the uploadId from the output of Initiate multipart
+```sh
+./s3curl.pl --id 'test:tester' --key 'testing' --put xaa -s 'http://localhost:8080/bucket/mobject?uploadId=<uploaIdFromPreviousStep>&partNumber=<partNumber>'
+```
+
+***c.complete the multi part***
+
+ ****c.1 List the part numbers and Etags****
+```sh
+./s3curl.pl --id 'test:tester' --key 'testing' -- "http://localhost:8080/bucket/mobject?uploadId=<uploadId>"
+```
+ ****c.2 make a xml file with following format and do a POST request****
+
+ example: cat ./complete_multi_tag
+```xml.
+<CompleteMultipartUpload>
+ <Part>
+ <PartNumber>1</PartNumber>
+ <ETag>"9dff188990a9831c5255d342895832df"</ETag>
+ </Part>
+ <Part>
+ <PartNumber>2</PartNumber>
+ <ETag>"72e117e4266579616ad295f399ae10a3"</ETag>
+ </Part>
+ <Part>
+ <PartNumber>3</PartNumber>
+ <ETag>"85c6e4487367f279926ad5da495a1d20"</ETag>
+ </Part>
+</CompleteMultipartUpload>
+```
+```sh
+./s3curl.pl --id 'test:tester' --key 'testing' --post ./complete_multi_tag -- http://localhost:8080/bucket/mobject?uploadId=<uploadId>
+```
+
+***d.download the multi part object***
+```sh
+./s3curl.pl --id 'test:tester' --key 'testing' -- "http://localhost:8080/bucket/mobject" > output_file
+```
**Using boto module in python to access GlusterFS cluster over S3 API**
```python