This adds aggregation of unprocessed items across multiple batch requests that a single dyno.putItems or dyno.deleteItems request might make. The scenario that is tested:
you have 25 valid records, then one invalid one, then 10 more valid ones in an array
you dyno.putItems
dyno completes a successful batchWriteItems request for the first 25 items, but the second request fails validation -- this results in no writes.
your dyno.putItems request returns an error, with err.unprocessed containing the 11 keys (including your invalid one) that were not written
Similar test scenario for dyno.deleteItems. Note that this is only tested for the case of user error, where you have handed dyno some invalid records. I don't have a good way to simulate a batch write request that say, makes 12 requests successfully, then fails due to networking problems, resulting in an additional 13 unprocessed items.
If any requested operations fail because the table's provisioned throughput is exceeded or an internal processing failure occurs, the failed operations are returned in the UnprocessedItems response parameter
Dynalite will never let me exceed provisioned throughput to test this.
Refs #80
This adds aggregation of unprocessed items across multiple batch requests that a single
dyno.putItems
ordyno.deleteItems
request might make. The scenario that is tested:dyno.putItems
batchWriteItems
request for the first 25 items, but the second request fails validation -- this results in no writes.dyno.putItems
request returns an error, witherr.unprocessed
containing the 11 keys (including your invalid one) that were not writtenSimilar test scenario for
dyno.deleteItems
. Note that this is only tested for the case of user error, where you have handed dyno some invalid records. I don't have a good way to simulate a batch write request that say, makes 12 requests successfully, then fails due to networking problems, resulting in an additional 13 unprocessed items.Dynalite will never let me exceed provisioned throughput to test this.
cc @emilymcafee @willwhite