vmware-go-kcl-v2/HyperMake
Tao Jiang 2ca82c25ca Add support for providing custom checkpointer (#17)
* Add credential configuration for resources

Add credentials for Kinesis, DynamoDB and Cloudwatch. See the worker_test.go
to see how to use it.

Signed-off-by: Tao Jiang <taoj@vmware.com>

* Add support for providing custom checkpointer

Provide a new constructor for adding checkpointer instead of alway using
default dynamodb checkpointer.

The next step is to abstract out the Kinesis into a generic stream API and
this will be bigger change and will be addressed in different PR.

Test:
  Use the new construtor to inject dynamodb checkpointer and run the existing
  tests.

Signed-off-by: Tao Jiang <taoj@vmware.com>

* Add support for providing custom checkpointer

Provide a new constructor for adding checkpointer instead of alway using
default dynamodb checkpointer.

The next step is to abstract out the Kinesis into a generic stream API and
this will be bigger change and will be addressed in different PR.

Fix checkfmt error.

Test:
  Use the new construtor to inject dynamodb checkpointer and run the existing
  tests.

Signed-off-by: Tao Jiang <taoj@vmware.com>
2021-12-20 21:21:14 -06:00

92 lines
1.7 KiB
Text

---
format: hypermake.v0
name: cascade-kinesis-client
description: Kinesis Client in Go
targets:
rebuild-toolchain:
description: build toolchain image
watches:
- support/docker/toolchain
build: support/docker/toolchain
toolchain:
description: placeholder for additional toolchain dependencies
deps:
description: download dependencies to local cache
after:
- toolchain
watches:
- go.mod
cmds:
- export GO111MODULE=on
- go mod download
- go mod vendor
build:
description: build source code
after:
- 'build-*'
test:
description: run unit tests
after:
- deps
- check
always: true
cmds:
- ./support/scripts/test.sh
ci:
description: run CI tests
after:
- deps
- check
cmds:
- ./support/scripts/ci.sh
checkfmt:
description: check code format
after:
- toolchain
watches:
- support/scripts/check.sh
always: true
cmds:
- ./support/scripts/check.sh fmt
lint:
description: run lint to check code
after:
- toolchain
watches:
- support/scripts/check.sh
always: true
cmds:
- ./support/scripts/check.sh lint
scanast:
description: run Go AST security scan
after:
- toolchain
watches:
- '**/**/*.go'
- './support/scripts/check.sh'
cmds:
- ./support/scripts/check.sh scanast
check:
description: run all code checks
after:
- checkfmt
- lint
- scanast
settings:
default-targets:
- ci
docker:
image: 'vmware/go-kcl-toolchain:0.1.2'
src-volume: /go/src/github.com/vmware/vmware-go-kcl