Skip to content
This repository has been archived by the owner on Oct 6, 2022. It is now read-only.

Add type wrapping #10

Merged
merged 1 commit into from
Jan 5, 2021
Merged

Add type wrapping #10

merged 1 commit into from
Jan 5, 2021

Conversation

jeroenvandijk
Copy link
Collaborator

  • response wrapping
  • request wrapping?
  • exception wrapping?
  • Test Add s3 test #9 ?

Manual test

(require '[babashka.pods :as pods])
(pods/load-pod ["clojure" "-M" "-m" "pod.babashka.aws"])
(require '[pod.babashka.aws :as aws])

(def s3 (aws/client {:api :s3}))

(aws/invoke s3 {:op :CreateBucket :request {:Bucket "babashka-test2"}})
(aws/invoke s3 {:op :ListBuckets}))

(def png (java.nio.file.Files/readAllBytes (.toPath (clojure.java.io/file "resources" "babashka.png"))))
(aws/invoke s3 {:op :PutObject :request {:Bucket "babashka-test2"
                                         :Key "logo.png"
                                         :Body png}})
                                         
(def res (aws/invoke s3 {:op :GetObject :request {:Bucket "babashka-test2" :Key "logo.png"}}))
                                         
(aws/invoke s3 {:op :DeleteObject :request {:Bucket "babashka-test2"  :Key "logo.png"}})
(aws/invoke s3 {:op :DeleteBucket :request {:Bucket "babashka-test2"}})

@borkdude borkdude merged commit b791121 into main Jan 5, 2021
@borkdude borkdude deleted the type-wrapping branch January 5, 2021 11:34
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants