Hi. Does anyone have an example or can explain how to work with ClientBuilders in AWS SDK in Clojure? I am can create a builder (AmazonKinesisVideoClient/builder)
but when trying to (.build)
it, I am getting all sorts of errors, eg - call to method withRegion can't be resolved (target class is unknown).
@dennisa paste your code
BTW Have you tried the Cognitect Labs aws client? Much more native feel
It's along the lines of
(doto (AmazonKinesisVideoClientBuilder/standard)
(.withRegion region-const)
(.withCredentials credential-provider)
....
(.build))
I haven't tried the cognitect aws client yet. It's more an API caller. It felt calling the Java SDK from Clojure would be more native : )
it's not :)
using the java sdk means making function calls to generate a bunch of objects which get turned into a bunch of http calls. the cognitect aws api is a functional api to make those http calls without all the junk in the middle
Isn't processing java objects returned by the SDK easier than parsing the output of the https calls ? : )
no, it's all autogenerated
amazon publishes data files describing the apis
https://www.youtube.com/watch?v=ppDtDP0Rntw if you're interested in more talking :)
also has autogenerated docs and clojure specs
Thank you, will have a look. I guess the cognitect aws client is similar to aws-cli in a way? Does the api it return the native Clojure data stuctures ? : )
takes data, returns data
you can find some examples here https://github.com/cognitect-labs/aws-api/blob/master/README.md#usage