Skip to content

Conversation

@glbrntt
Copy link
Collaborator

@glbrntt glbrntt commented Aug 14, 2020

Motivation:

Sometimes it's useful to know what's going on at the HTTP/2 layer, none
of our logs currently surface this information.

Modifications:

  • Add logs for stream created/closed events (includes open stream count)
  • Add logs for initial settings
  • Add more logging for connection lifecycle
  • Add trace logs to the stream for read/written frames
  • Prefix request and connection ID metadata keys with "grpc_"
  • Remove duplicated log messages

Result:

  • Better insight for HTTP/2

@glbrntt glbrntt requested a review from Lukasa August 14, 2020 14:29
@glbrntt glbrntt added the 🔨 semver/patch No public API change. label Aug 14, 2020
handler: @escaping (Deserializer.Output) -> Void
) -> BidirectionalStreamingCall<Serializer.Input, Deserializer.Output> {
let (logger, requestID) = self.populatedLoggerAndRequestID(from: callOptions)
logger.debug("starting rpc", metadata: ["path": "\(path)"])
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the theory we don't need these anymore?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are duplicates.

Motivation:

Sometimes it's useful to know what's going on at the HTTP/2 layer, none
of our logs currently surface this information.

Modifications:

- Add logs for stream created/closed events (includes open stream count)
- Add logs for initial settings
- Add more logging for connection lifecycle
- Add trace logs to the stream for read/written frames
- Prefix request and connection ID metadata keys with "grpc_"
- Remove duplicated log messages

Result:

- Better insight for HTTP/2
@glbrntt glbrntt requested a review from Lukasa August 18, 2020 10:02
@glbrntt glbrntt merged commit 07432c4 into grpc:main Aug 18, 2020
@glbrntt glbrntt deleted the gb-more-logging branch August 18, 2020 12:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🔨 semver/patch No public API change.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants