Skip to content

Commit 6ba725a

Browse files
committed
add more services
1 parent e1f2b52 commit 6ba725a

File tree

3 files changed

+8922
-643
lines changed

3 files changed

+8922
-643
lines changed

README.md

+10-3
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
# pod-tzzh-aws
22

3-
A WIP [pod](https://github.com/babashka/babashka.pods) to interact with AWS using [babashka](https://github.com/borkdude/babashka/).
3+
A [pod](https://github.com/babashka/babashka.pods) to interact with AWS using [babashka](https://github.com/borkdude/babashka/).
44

55
[This file](./babashka/babashka.go) contains the code around receiving/sending bencoded messages from/to babashka.
66

7-
Then [this](./gen/generate.clj) generates all the code to use the golang sdk. That might be a bit too hacky but allows to have access to most of the AWS sdk really quickly and I believe this is relatively common in Go to get around the lack of generics.
7+
Then [this](./gen/generate.clj) generates all the code to use the golang sdk. That might be a bit hacky but allows to have access to most of the AWS sdk really quickly and I believe this is relatively common in Go to get around the lack of generics.
88

9-
Currently most dynamodb and s3 functions are supported (adding other services should be easy in most cases as the code is mostly auto generated).
9+
Currently most of the sdk for dynamodb, s3, athena, glue, kafka, kinesis, lambda, sqs, ssm is included.
10+
11+
It is a bit random, it's basically based on what I think is popular and what I need. The code is autogenerated so more services can be added if they are needed. I didn't try to include everything to avoid ending up with a huge binary.
1012

1113
## Usage
1214

@@ -38,10 +40,14 @@ Get the latest release and then:
3840

3941
(s3/list-buckets)
4042

43+
;; Paginators example
4144
(let [s3-paginator (p/get-paginator s3/list-objects-v2-pages)]
4245
(s3-paginator {:Bucket "some-bucket"
4346
:Prefix "some-prefix/something/"}))
4447
;; this returns a list of all the pages i.e a list of ListObjectsV2Output that are lazily fetched
48+
49+
(let [glue-paginator (p/get-paginator g/list-crawlers)]
50+
(glue-paginator))
4551
```
4652

4753
## Paginators
@@ -54,3 +60,4 @@ func (c *S3) ListObjectsV2Pages(input *ListObjectsV2Input, fn func(*ListObjectsV
5460
Whereas in the Python sdk, the paginators are instead generators that lazily loads the pages.
5561
This approach is more functional and has been copied here.
5662
To use it you need to use the `get-paginator` fn from the `pod.tzzh.paginator` namespace and pass the fn you need to use as an argument to `get-paginator` as shown in the example above.
63+
The functions that use either `NextContinuationToken`, `NextToken` and `NextMarker` to paginate can currently be paginated.

0 commit comments

Comments
 (0)