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 réponses
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
répondu il y a 7 mois
profile picture
EXPERT
vérifié il y a 2 mois
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
répondu il y a 7 mois

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions