Constructor
new DynamoWriteQueue(dynamoCredentials, dynamoRegion, tableName)
Constructor for DynamoWriteQueue
Parameters:
Name | Type | Description |
---|---|---|
dynamoCredentials |
module:dynamo.DynamoCredentials | The credentials for a Dynamo table |
dynamoRegion |
string | The region of the Dynamo table we're using |
tableName |
string | The name of the table we want to store data in |
Methods
push(item, callbacknullable) → {void}
Method to push items to our queue
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
item |
module:DynamoWriteQueue.WriteQueueItem | Any item that we want to push to Dynamo |
|
callback |
function |
<nullable> |
A method to call once the item has been stored |
Returns:
Nothing
- Type
- void
pushBatch(batch, callbacknullable) → {void}
Method to push items to our queue
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
batch |
Array.<module:DynamoWriteQueue.WriteQueueItem> | A batch of items to push into the queue |
|
callback |
function |
<nullable> |
A method to call once the item has been stored |
Returns:
Nothing
- Type
- void