How to get DocumentDB change stream arn

0

Hello, I am trying to set up a Lambda, subscribed to a DocumentDB change stream and do it via Cloud Formation I am reading from https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html#cfn-lambda-eventsourcemapping-eventsourcearn

EventSourceArn ... Amazon DocumentDB – The ARN of the DocumentDB change stream.

but i am not able to find the change stream arn in the DocumentDB UI ( i have the change stream enabled already )

Georgi
asked 20 days ago129 views
3 Answers
0

unfortunately i get

$ aws docdb describe-change-streams --db-cluster-identifier xxxxxxx

usage: aws [options] <command> <subcommand> [<subcommand> ...] [parameters]
To see help text, you can run:

  aws help
  aws <command> help
  aws <command> <subcommand> help

aws: error: argument operation: Invalid choice, valid choices are:

...
describe-db-cluster-parameter-groups     | describe-db-cluster-parameters          
describe-db-cluster-snapshot-attributes  | describe-db-cluster-snapshots           
describe-db-clusters                     | describe-db-engine-versions             
describe-db-instances                    | describe-db-subnet-groups               
describe-engine-default-cluster-parameters | describe-event-categories               
describe-event-subscriptions             | describe-events                         
describe-global-clusters                 | describe-orderable-db-instance-options  
describe-pending-maintenance-actions     | failover-db-cluster      
...

so describe-change-streams is not a valid option

also not listed here: https://docs.aws.amazon.com/cli/latest/reference/docdb/

Georgi
answered 20 days ago
0

probably i need https://docs.aws.amazon.com/cli/latest/reference/docdb/describe-event-subscriptions.html

but that implies that i have already created the subscription

so to summarize: in order to set an eventSourceMapping ( see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html ) i need to set a subscription ( see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-eventsubscription.html ) for which in turn i need to setup an SNS topic ( see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-sns-topic.html ) still WIP, will update the comment once i succeed ( or fail ) with this

Georgi
answered 20 days ago
-1
aws docdb describe-change-streams \
    --db-cluster-identifier your-cluster-name
profile picture
answered 20 days ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions