This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-05-25
Channels
- # aws (10)
- # babashka (4)
- # beginners (103)
- # calva (19)
- # chlorine-clover (2)
- # cider (10)
- # cljs-dev (23)
- # cljsrn (6)
- # clojure (145)
- # clojure-europe (17)
- # clojure-nl (1)
- # clojure-spec (11)
- # clojure-uk (4)
- # clojurescript (64)
- # conjure (11)
- # core-async (19)
- # cursive (38)
- # datomic (4)
- # duct (2)
- # fulcro (51)
- # helix (11)
- # joker (1)
- # kaocha (7)
- # leiningen (3)
- # malli (5)
- # meander (3)
- # off-topic (12)
- # pathom (17)
- # pedestal (2)
- # re-frame (27)
- # rum (11)
- # shadow-cljs (77)
- # xtdb (9)
- # yada (1)
No matter what I do, I cannot get endpoint configuration into place in such a way that AWS SDK or Amazonica would like it
All I get is
java.lang.IllegalStateException: S3 client with invalid S3 endpoint configured: my-localstack-domain:4566
This happens at
com.amazonaws.services.s3.AmazonS3Client.getRegion(AmazonS3Client.java:4590)
Which makes sense since Amazonica is leaving region as nil
on purpose https://github.com/mcohen01/amazonica/blob/master/src/amazonica/core.clj#L162
I however cannot create that EndpointConfiguration object myself and pass it in since Amazonica is expecting a string
Managed to hack past that with this:
(with-redefs [amazonica.core/build-client (constantly
(-> (AmazonS3ClientBuilder/standard)
(.enablePathStyleAccess)
(.withEndpointConfiguration (AwsClientBuilder$EndpointConfiguration.
(format "" host port)
"eu-central-1"))
(.build)))]
(s3/list-buckets))