updated lambda to reduce traffic

This commit is contained in:
Gert Wohlgemuth 2018-06-06 22:48:37 -07:00
parent 1611cd8124
commit 63591fae9c

View File

@ -1,3 +1,5 @@
from time import sleep
import boto3
import simplejson as json
import os
@ -19,7 +21,7 @@ def store(event, context):
for x in data:
print("storing data: {}".format(x))
sleep(0.5) # throttle to not overwhelm the DB, lambda is cheaper than dynamo
get_trade_table().put_item(Item=x)