How do I create an OpenSearch subscription for CloudWatch using the API?

0

It's possible to stream CloudWatch logs to OpenSearch. The process of setting up the subscription via the UI ids described here: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_OpenSearch_Stream.html. Is there a way of setting this up using the API or CloudFormation? It's not listed as an option here: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutSubscriptionFilter.html

1 Resposta
0

I recommend taking a look at sample CloudFormation templates such as this one and another one here. When you create a subscription to stream logs to OpenSearch, a Lambda function is used to stream logs. Therefore, there is no single API to set up the subscription. Instead, you will need to create a subscription with a destination set for Lambda.

AWS
Taka_M
respondido há 2 anos

Você não está conectado. Fazer login para postar uma resposta.

Uma boa resposta responde claramente à pergunta, dá feedback construtivo e incentiva o crescimento profissional de quem perguntou.

Diretrizes para responder a perguntas