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

feat(snownet): log duration since intent after WG handshake completes #3991

Merged
merged 5 commits into from
Mar 9, 2024

Conversation

thomaseizinger
Copy link
Member

Preceded by some refactoring, this PR adds a log line with a very important metric: Time since connection intent after WG handshake. This is the equivalent of time-to-first-byte, i.e. how long the user needs to wait to actually send their first application data after they've tried for the firs time (and generated an intent).

Copy link

vercel bot commented Mar 6, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
firezone ⬜️ Ignored (Inspect) Visit Preview Mar 9, 2024 9:29am

Copy link

github-actions bot commented Mar 6, 2024

Terraform Cloud Plan Output

Plan: 8 to add, 7 to change, 8 to destroy.

Terraform Cloud Plan

Copy link

github-actions bot commented Mar 6, 2024

Performance Test Results

TCP

Test Name Received/s Sent/s Retransmits
direct-tcp-client2server 63.5 MiB (-1%) 64.1 MiB (-1%) 55 (+8%)
direct-tcp-server2client 52.3 MiB (-4%) 52.6 MiB (-4%) 29 (-26%)
relayed-tcp-client2server 29.1 MiB (-1%) 31.9 MiB (+2%) 1 (-99%)
relayed-tcp-server2client 28.2 MiB (+1%) 31.1 MiB (+2%) 436 (+69%)

UDP

Test Name Total/s Jitter Lost
direct-udp-client2server 50.0 MiB (-0%) 0.18ms (-5%) 0.00% (NaN%)
direct-udp-server2client 50.0 MiB (+0%) 0.21ms (-4%) 0.00% (NaN%)
relayed-udp-client2server 50.0 MiB (-0%) 0.31ms (-6%) 26.09% (+37%)
relayed-udp-server2client 50.0 MiB (-0%) 0.31ms (-24%) 19.83% (-22%)

@thomaseizinger thomaseizinger force-pushed the feat/snownet/connection-establish-time branch from 61b5701 to 8c17cc2 Compare March 7, 2024 02:24
@thomaseizinger thomaseizinger force-pushed the feat/snownet/connection-establish-time branch 2 times, most recently from 5351880 to e509715 Compare March 8, 2024 00:03
@thomaseizinger
Copy link
Member Author

@conectado I ended up buiilding #4047 on top of this which undoes a few of the changes in here. However, it was easier to just layer it on top rather than starting again and having lots of conflicts.

This PR should be non-controversial so if you have any feedback on the internal design, I'd suggest to leave it on #4047.

Thanks! :)

Copy link
Collaborator

@conectado conectado left a comment

Choose a reason for hiding this comment

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

Nice to have this metric :)

Do you think it's worth it to add a similar comment to what we have with iperf to detect regressions earlier?

stun_servers: HashSet<SocketAddr>,
turn_servers: HashSet<SocketAddr>,

stats: ConnectionStats,

buffer: Box<[u8; MAX_UDP_SIZE]>,
Copy link
Collaborator

Choose a reason for hiding this comment

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

the buffer name feels a bit generic here

Copy link
Member Author

Choose a reason for hiding this comment

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

That is changing in the follow-up PR I linked above!

@thomaseizinger
Copy link
Member Author

Do you think it's worth it to add a similar comment to what we have with iperf to detect regressions earlier?

It would be nice to assert automatically but we'd need some form of structured reporting of these metrics like OTEL or prometheus.

@thomaseizinger thomaseizinger added this pull request to the merge queue Mar 9, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to a conflict with the base branch Mar 9, 2024
@thomaseizinger thomaseizinger force-pushed the feat/snownet/connection-establish-time branch from e509715 to eb85bf8 Compare March 9, 2024 09:22
@thomaseizinger thomaseizinger force-pushed the feat/snownet/connection-establish-time branch from eb85bf8 to d581aea Compare March 9, 2024 09:29
@thomaseizinger thomaseizinger added this pull request to the merge queue Mar 9, 2024
Merged via the queue into main with commit e64189c Mar 9, 2024
64 checks passed
@thomaseizinger thomaseizinger deleted the feat/snownet/connection-establish-time branch March 9, 2024 09:55
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.

None yet

2 participants