diff --git a/doc/index.html b/doc/index.html index 82e8cf8..0fa12c2 100644 --- a/doc/index.html +++ b/doc/index.html @@ -31,7 +31,7 @@
+ Some operations return a response as an additional value. All + response objects can be interrogated to obtain the HTTP code, + headers and phrase. +
The response to some requests — a very small proportion @@ -408,17 +414,94 @@
If a requst fails more times than permitted by
- *backoff*
, an error will be signalled:
-
*backoff*
, an error will be signalled. It is the
+ application's responsibility to handle this error.
+
++* e +#<ZS3::INTERNAL-ERROR @ #x1000296bc92> +* (setf r (zs3:request-error-response e)) +#<ZS3::AMAZON-ERROR "InternalError"> +* (zs3:http-code r) +500 +* (zs3:http-headers r) +((:X-AMZ-REQUEST-ID . "3E20E3BAC24AB9AA") + (:X-AMZ-ID-2 . "80sxu4PDKtx1BWLOcSrUVWD90mMMVaMx6y9c+sz5VBGa2eAES2YlNaefn5kqRsfvrbaF+7QGNXA=") + (:CONTENT-TYPE . "application/xml") + (:TRANSFER-ENCODING . "chunked") + (:DATE . "Fri, 30 Sep 2016 10:10:11 GMT") + (:CONNECTION . "close") + (:SERVER . "AmazonS3")) +* (zs3:http-phrase r) +"Internal Server Error" +*+ + + -
(ERROR #<ZS3::INTERNAL-ERROR @ #x10008f1a8b2>)-
- It is the application's responsibility to handle this.
+request-error-response
+
+ request-error
+
+ => response
+ ++Returns the
response
object associated with a request-error. +
http-code
+
+ response
+
+ => code
+ +Returns the HTTP code associated with a
response
object.
http-headers
+
+ response
+
+ => headers
+ ++Returns the HTTP headers associated with a
response
object. +
http-phrase
+
+ response
+
+ => phrase
+ ++Returns the HTTP phrase associated with a
response
object. +
@@ -598,7 +681,7 @@Contents
credentials backoff - => | + => response@@ -658,7 +741,7 @@Contents
rules bucket - => | + => rules, response@@ -737,7 +820,7 @@Contents
credentials backoff - => | + => response@@ -1316,7 +1399,7 @@Contents
credentials backoff - => | + => response@@ -1398,7 +1481,7 @@Contents
credentials backoff - => | + => response@@ -1435,7 +1518,7 @@Contents
credentials backoff - => | + => response@@ -1469,7 +1552,7 @@Contents
credentials backoff - => | + => response@@ -1511,7 +1594,7 @@Contents
credentials backoff - => | + => response@@ -1560,7 +1643,7 @@Contents
credentials backoff - => | + => response@@ -1610,7 +1693,7 @@Contents
credentials backoff - => | + => response@@ -1707,7 +1790,7 @@Contents
credentials backoff - => | + => response@@ -1777,7 +1860,7 @@Contents
credentials backoff - => | + => response@@ -1953,7 +2036,7 @@Contents
credentials backoff - => | + => response@@ -1974,7 +2057,7 @@Contents
credentials backoff - => | + => response@@ -2007,7 +2090,7 @@Contents
credentials backoff - => | + => response@@ -2027,7 +2110,7 @@Contents
credentials backoff - => | + => response@@ -2051,7 +2134,7 @@Contents
credentials backoff - => | + => response@@ -2080,7 +2163,7 @@Contents
credentials backoff - => | + => responsediff --git a/lifecycle.lisp b/lifecycle.lisp index 8abb7ad..5588add 100644 --- a/lifecycle.lisp +++ b/lifecycle.lisp @@ -221,12 +221,14 @@ configuration is deleted with DELETE-BUCKET-LIFECYCLE." (setf rules (list rules))) (let* ((content (lifecycle-document rules)) (md5 (vector-md5/b64 content))) - (submit-request (make-instance 'request - :method :put - :bucket bucket - :sub-resource "lifecycle" - :content-md5 md5 - :content content)))) + (values + rules + (submit-request (make-instance 'request + :method :put + :bucket bucket + :sub-resource "lifecycle" + :content-md5 md5 + :content content))))) ;;; Restoring from glacier diff --git a/package.lisp b/package.lisp index 444b701..a78dcb1 100644 --- a/package.lisp +++ b/package.lisp @@ -35,8 +35,12 @@ #:access-key #:secret-key #:file-credentials) - ;; Backoff - (:export #:*backoff*) + ;; Responses + (:export #:*backoff* + #:request-error-response + #:http-code + #:http-headers + #:http-phrase) ;; Buckets (:export #:all-buckets #:creation-date