Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debug log all dials #727

Merged
merged 2 commits into from
Feb 28, 2024
Merged

Debug log all dials #727

merged 2 commits into from
Feb 28, 2024

Conversation

mmatczuk
Copy link
Contributor

@mmatczuk mmatczuk commented Feb 28, 2024

Fixes #645

This is a temporary solution until we have context-aware logging everywhere.
It allows us to log the network and address of the connection being established together with the trace ID.
2024/02/28 14:55:23.447579 [proxy] [DEBUG] closing connection from 127.0.0.1:54332 duration=1.982912042s
2024/02/28 14:56:10.294136 [proxy] [DEBUG] accepted connection from 127.0.0.1:54337
2024/02/28 14:56:10.294249 [proxy] [DEBUG] [2-4c948b90] read CONNECT request host=google.com:443
2024/02/28 14:56:10.294267 [proxy] [DEBUG] [2-4c948b90] CONNECT to host directly: google.com:443
2024/02/28 14:56:10.294271 [proxy] [DEBUG] [2-4c948b90] opening connection to tcp google.com:443
2024/02/28 14:56:10.353445 [proxy] [DEBUG] [2-4c948b90] connection to tcp google.com:443 established duration=59.166ms

Fixes #645
@mmatczuk mmatczuk merged commit 6ad7638 into main Feb 28, 2024
4 checks passed
@mmatczuk mmatczuk deleted the mmt/log_dial branch February 28, 2024 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

martian: add logging when new connections are dialed
2 participants