Can you attach multiple log groups to the same lambda used for Cloudwatch Log Group to Opensearch subscriptions.

0

Hi,

I've used the subscription -> Create -> Create Amazon OpenSearch Service subscription filter. I had a single log group working via this and can see the data in opensearch.

I have now updated another cloudwatch log group to use the amazon opensearch service subscription filter. This apparently uses the same lambda that is created from the first log group filter. but i dont see any new data in opensearch. If i filter out the logs from the first, its empty.

Is it possible to have multiple cloudwatch log groups use the built in option? Or should we look at copying the lambda function it creates and just doing a lambda filter instead of opensearch?

2 Answers
0

Yes, you can have multiple CloudWatch Log Groups streaming data to Amazon OpenSearch Service (or its successor, Amazon Elasticsearch Service) using a single Lambda function. Each Log Group can have its own subscription filter, and they can all point to the same Lambda function.

Regards, Andrii

profile picture
EXPERT
answered 6 months ago
profile picture
EXPERT
reviewed a month ago
0

Any idea why mine isnt populating then?

First log group subscription works, but second i get no data. Ive just created a new lambda function and pointed it at, and straight away the logs go into opensearch.

oc
answered 6 months 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