Skip to content

@requestId is not logged for metrics log line when using in Lambda #101

@heartsword2017

Description

@heartsword2017

Hi,

I am using this library in my Lambda to log custom metrics. When using it, I observe for the EMF log line it will add those Lambda autogenerated fields like @ingestionTime, @logstream, @message, @timestamp and etc but @requsetId is missing from it. Other normal log lines generated from code will always have @requestid.

The problem caused is when we use log Insight to search for all logs of a specific Lambda invocation by filter @requestId = "something", with @requestid missed on this line, it won't show up in search result.

See the picture for details.
@requestid is missed
1

when searching logs with @requestid, EMF log line is not included due to missing @requestid
2

Do we think this is something we can fix?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions