Last active
March 27, 2020 14:21
Star
You must be signed in to star a gist
DataDog Log Pipeline for Lambda Logs - Grok Parser
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#### JSON Rules | |
#2018-08-22T11:05:02.637Z 4d8b3785-079a-5f47-9b09-647242079aed {"level": "INFO", "message": "that's an interesting message", "user": "john"} | |
log_json_rule %{date("yyyy-MM-dd'T'HH:mm:ss.SSSZ"):timestamp}\s+%{notSpace:lambda.request_id}\s+%{regex("\\{.*\\}")::json} | |
#### Plain Text Rules | |
#2018-08-22T11:05:02.637Z 4d8b3785-079a-5f47-9b09-647242079aed INFO: that's an interesting message | |
log_level_msg_rule %{date("yyyy-MM-dd'T'HH:mm:ss.SSSZ"):timestamp}\s+%{notSpace:lambda.request_id}\s+%{regex("/(?i)ERROR|WARN|INFO|DEBUG|TRACE/"):level}:?\s+%{data:message} | |
#2018-08-22T11:05:02.637Z 4d8b3785-079a-5f47-9b09-647242079aed that's an interesting message | |
log_msg_rule %{date("yyyy-MM-dd'T'HH:mm:ss.SSSZ"):timestamp}\s+%{notSpace:lambda.request_id}\s+%{data:message} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment