Skip to content
This repository has been archived by the owner on Jul 28, 2023. It is now read-only.

Commit

Permalink
use pay per request for DynamoDB tables (#127)
Browse files Browse the repository at this point in the history
  • Loading branch information
musketyr authored Jul 28, 2023
1 parent 89e0ff8 commit 5a87863
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import com.amazonaws.auth.AWSCredentialsProvider
import com.amazonaws.auth.DefaultAWSCredentialsProviderChain
import com.amazonaws.regions.Region
import com.amazonaws.regions.ServiceAbbreviations
import com.amazonaws.services.dynamodbv2.model.BillingMode
import com.amazonaws.services.kinesis.AmazonKinesisClient
import com.amazonaws.services.kinesis.clientlibrary.interfaces.IRecordProcessorFactory
import com.amazonaws.services.kinesis.clientlibrary.lib.worker.InitialPositionInStream
Expand Down Expand Up @@ -87,6 +88,7 @@ abstract class AbstractClientService {
.withRegionName(region.name)
.withInitialPositionInStream(InitialPositionInStream.LATEST)
.withIdleTimeBetweenReadsInMillis(idleTimeBetweenReadsInMillis)
.withBillingMode(BillingMode.PAY_PER_REQUEST)

// Create a new worker for each stream
Worker worker = new Worker(recordProcessorFactory, kclConfig)
Expand Down

0 comments on commit 5a87863

Please sign in to comment.