amazon-cloudwatchlogs

Microsoft Teams escaping underscores in text

浪尽此生 提交于 2021-02-08 11:38:50
问题 I have following function in ruby to send aws logs to microsoft team channel through webhook. Some text contains underscore signs like connection_web but appears like connectionweb in MS teams. How to get the exact output ? require 'json' require 'net/https' require 'uri' require 'base64' require 'zlib' require 'stringio' def lambda_handler(event:, context:) log_event = JSON.parse(decode_and_decompress(event["awslogs"]["data"])) response = speak(messages_from_blob(log_event)) puts response

Microsoft Teams escaping underscores in text

北战南征 提交于 2021-02-08 11:38:43
问题 I have following function in ruby to send aws logs to microsoft team channel through webhook. Some text contains underscore signs like connection_web but appears like connectionweb in MS teams. How to get the exact output ? require 'json' require 'net/https' require 'uri' require 'base64' require 'zlib' require 'stringio' def lambda_handler(event:, context:) log_event = JSON.parse(decode_and_decompress(event["awslogs"]["data"])) response = speak(messages_from_blob(log_event)) puts response

NoCredentialProviders error with awslogs logging driver in docker at mac

元气小坏坏 提交于 2021-02-07 20:52:07
问题 Hi I am trying to enable cloud watch logging in my docker container on my mac machine. Docker version . Version: 18.03.1-ce . API version: 1.37 . I am getting following error every-time i start container Error response from daemon: failed to initialize logging driver: NoCredentialProviders: no valid providers in chain. Deprecated. For verbose messaging see aws.Config.CredentialsChainVerboseErrors I have tried following approaches: Exporting AWS_ACCESS_KEY_ID (etc.) in /etc/default/docker

NoCredentialProviders error with awslogs logging driver in docker at mac

笑着哭i 提交于 2021-02-07 20:46:14
问题 Hi I am trying to enable cloud watch logging in my docker container on my mac machine. Docker version . Version: 18.03.1-ce . API version: 1.37 . I am getting following error every-time i start container Error response from daemon: failed to initialize logging driver: NoCredentialProviders: no valid providers in chain. Deprecated. For verbose messaging see aws.Config.CredentialsChainVerboseErrors I have tried following approaches: Exporting AWS_ACCESS_KEY_ID (etc.) in /etc/default/docker

NoCredentialProviders error with awslogs logging driver in docker at mac

心已入冬 提交于 2021-02-07 20:44:10
问题 Hi I am trying to enable cloud watch logging in my docker container on my mac machine. Docker version . Version: 18.03.1-ce . API version: 1.37 . I am getting following error every-time i start container Error response from daemon: failed to initialize logging driver: NoCredentialProviders: no valid providers in chain. Deprecated. For verbose messaging see aws.Config.CredentialsChainVerboseErrors I have tried following approaches: Exporting AWS_ACCESS_KEY_ID (etc.) in /etc/default/docker

How to use a CloudWatch custom log group with Python Shell Glue job?

自作多情 提交于 2021-01-04 03:21:34
问题 I have some "Python Shell" type Glue jobs and I want to send the job logs to a custom CloudWatch log group instead of the default log group. I am able to achieve this for "Spark" type glue jobs by providing job parameters as below: "--enable-continuous-cloudwatch-log" = true "--continuous-log-logGroup" = "/aws-glue/jobs/glue-job-1" but the same parameters doesn't work for Python Shell jobs (logs still going to the default log groups /aws-glue/python-jobs/output and /aws-glue/python-jobs/error

How to use a CloudWatch custom log group with Python Shell Glue job?

此生再无相见时 提交于 2021-01-04 03:17:36
问题 I have some "Python Shell" type Glue jobs and I want to send the job logs to a custom CloudWatch log group instead of the default log group. I am able to achieve this for "Spark" type glue jobs by providing job parameters as below: "--enable-continuous-cloudwatch-log" = true "--continuous-log-logGroup" = "/aws-glue/jobs/glue-job-1" but the same parameters doesn't work for Python Shell jobs (logs still going to the default log groups /aws-glue/python-jobs/output and /aws-glue/python-jobs/error

AWS Lambda and API Gateway response integration issue

生来就可爱ヽ(ⅴ<●) 提交于 2020-04-30 04:37:50
问题 I have deployed AWS stack with a Lambda function and an API gateway. After deployment I tested Lambda function independently and it works fine but when I invoke it using AWS API Gateway, it fails with ` Internal Error: 502 I looked at cloudwatch logs and it says Endpoint response body before transformations: null I am returning my response from Lambda (Python 3.6) in following way - body = { "message": "Success!!" } response = { "statusCode": 200, "headers": { "content-type": "application

AWS Cloudwatch Json Metric Filter Pattern

ぃ、小莉子 提交于 2020-02-25 05:43:05
问题 Following the Amazon Example for Json Metric Filter, I tried to copy their example. In the process of creating a metric filter, you can test it with example logs first. So I went for "Custom Log", copy-pasted the example from the link given above: { "eventType": "UpdateTrail", "sourceIPAddress": "111.111.111.111", "arrayKey": [ "value", "another value" ], "objectList": [ { "name": "a", "id": 1 }, { "name": "b", "id": 2 } ], "SomeObject": null, "ThisFlag": true } and my pattern is: { $