Reputation: 259
Does anyone have a good example using AWS DynamoDB DAX in node.js? And what needs to be considered? (E.g. VPC, Subnet, Security Group, etc.).
I am getting
Error: NoRouteException: No endpoints available
and partially
Error: ValidationException: One of the required keys was not given a value
Don't get data stored, not in the cache, nor on the DB.
Thank you!
Upvotes: 2
Views: 2212
Reputation: 7662
There is the TryDax example in the documentation, which describes how to access data using both DynamoDB and DAX - the DAX client should be a drop in replacement. The second error is most likely just a missing part of the key.
Getting VPCs and subnets set up is a bit more involved - the client machine and the cluster must be in the same VPC (or peered VPCs) and both must be in a security group that allows traffic from the client to the cluster. You also need IAM policies and roles configured correctly so that DAX can authenticate the client.
Upvotes: 2