aws-samples / aws-lambda-fanout

A sample AWS Lambda function that accepts messages from an Amazon Kinesis Stream and transfers the messages to another data transport.
Apache License 2.0
288 stars 60 forks source link

Cannot use custom config table name #23

Open joe-mojo opened 7 years ago

joe-mojo commented 7 years ago

When creating a lambda with a specific table name, then issuing all needed command with --table-arn leads to a non-working lambda looking for table <function name>Targets instead of the specified table arn/name. The specified table name is created in Dynamo, but lambda will look for <function name>Targets. Unregistering such a lambda gives an error message saying that <function name>Targets table doesn't exist, while a valid table arn was issued.

Looking at code, it looks like table name and table arn are used by shell scripts to issue the right aws-cli commands, so we have the right names for created lambda, created dynamo table, source, etc. The shell scripts sets TABLE_NAME and TABLE_ARN variables correctly, but no trace of them in lambda js code.

ebahsini commented 7 years ago

@joe-mojo had similar issue today, hacked this together. Let me know if this works for you

rafalszota commented 6 years ago

Same for me. In the end I sticked to the default table name, since I was not really willing to edit JS code.

jeremyber-aws commented 2 years ago

+1 to this issue. Confirmed it does not work.