考虑日志输出:
2018-07-09 14:59:48,938 INFO [req-id:aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa] [sqs-m-id:aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa] [bucket:my-bucket] [s3Key:folder/myFile.pdf] com.mycompany.MyJavaClass - some message with spaces
2018-07-09 14:59:48,938 INFO [req-id:bbbbbbbb-bbbb-bbbb-bbbb-bbbbbbbbbbbb] [sqs-m-id:bbbbbbbb-bbbb-bbbb-bbbb-bbbbbbbbbbbb] [bucket:my-bucket] [s3Key:folder/myOtherFile.pdf] com.mycompany.MyJavaClass - some other message also with spaces
2018-07-09 14:59:48,938 INFO [req-id:bbbbbbbb-bbbb-bbbb-bbbb-bbbbbbbbbbbb] [sqs-m-id:bbbbbbbb-bbbb-bbbb-bbbb-bbbbbbbbbbbb] [bucket:my-bucket] [s3Key:folder/myOtherFile.pdf] com.mycompany.MyJavaClass - ELAPSED_TIME_NS 1520093301
START RequestId: aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa Version: $LATEST
如何提取仅应用于ELAPSED_TIME_NS
行的指标。并从中获取价值?
答案 0 :(得分:1)
此模式应为您工作:
[..., message=ELAPSED_TIME_NS, nanoseconds]