Is it possible to retrieve a Stream ARN for a table that is not created by the serverless.yml I’m writing? I’m working on a solution to replicate DynamoDB tables to Redshift using Firehose, but the tables weren’t created by me. All I really need is to create/enable the Stream in a given table and reference that stream ARN in my template somewhere else, or just retrieve an existing Stream ARN based on the table name.
So far I wasn’t able to figure out if Serverless allows me to reference a pre-existing DynamoDB table or not. If it doesn’t, I’m not able to fully automate the deployment and will need to provide the stream ARNs manually in my template, for each table and for each account I’ll use it.
Sure… You just need the arn of the dynamo stream. You can retrieve that via the AWS Console.
It’s listed on the Overview tab when you select the table.
The Stream arn is static unless you drop and re-create it(or the underlying table). When ti does change, only the date-time at the end of the arn. So be sure to update the arn on your handler if you alter the stream source.
I know I am late to this.
I was having the same problem, to automate the deployment I cannot copy and paste ARN again and again. Even asked this on StackOverflow
What I found was that we can basically do this by using AWS DynamoDB Describe Streams Method. link here: API_streams_DescribeStream
In case someone wants an implementation, I wrote a serverless plugin that fetches and attach ARN
link here: serverless-dynamodb-stream-arn-plugin