Warm tip: This article is reproduced from serverfault.com, please click

dynamodb streams adapter for KCL in Java SDK v2.x

发布于 2020-11-28 11:07:31

There's this document on AWS that suggests the best way to consume a dynamoDB Stream is via Kinesis Client Library using an adapter to translate between kinesis stream and dynamodb stream API.

This is the document: https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/Streams.KCLAdapter.html

And these are maven coordinates for the adapter implementation

  <groupId>com.amazonaws</groupId>
  <artifactId>dynamodb-streams-kinesis-adapter</artifactId>
  <version>1.5.2</version>

This works for Java SDK v1.x

Considering that Java SDK v2.x has been out for a while, is there an equivalent adapter for KCL v2.x? Or perhaps it's somehow built in the SDK itself?

Questioner
artur
Viewed
0
artur 2020-12-03 17:09:51

Answering my own question after researching a bit more.

There seem to be no equivalent of Dynamodb Streams adapter for KCL 2.x and Java SDK 2.x, so you'll need to roll out your own if you want to consume dynamodb stream with KCL 2.x.

Also, around 2 weeks ago a new feature has been added to Dynamodb that allows to stream item changes directly to Kinesis streams. This then allows to use KCL 2.x without any adapters. https://aws.amazon.com/about-aws/whats-new/2020/11/now-you-can-use-amazon-kinesis-data-streams-to-capture-item-level-changes-in-your-amazon-dynamodb-table/