BatchWrite currently handles the situation where some of the writes have failed and BatchWrite will retry those records. However, the API says:
If none of the items can be processed due to insufficient provisioned throughput on all of the tables in the request, then BatchWriteItem returns a ProvisionedThroughputExceededException.
In the situation that batchWriteItem throws a ProvisionedThroughputExceededException, then BatchWrite should add all items in the request back to the queue to be re-attempted.
BatchWrite
currently handles the situation where some of the writes have failed andBatchWrite
will retry those records. However, the API says:In this situation, the exception will be thrown at this line and simply left to bubble up the stack rather than retrying all items in the request. https://github.com/awslabs/dynamodb-data-mapper-js/blob/d52b9dfea14851235843a0879e5754822c0e462d/packages/dynamodb-batch-iterator/src/BatchWrite.ts#L49
In the situation that
batchWriteItem
throws aProvisionedThroughputExceededException
, thenBatchWrite
should add all items in the request back to the queue to be re-attempted.