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

Add (external) connections stats to #NetVisualisation graph #10456

Merged
merged 1 commit into from
Nov 14, 2024

Conversation

sgothel
Copy link

@sgothel sgothel commented Nov 9, 2024

  • Resolves: #
  • Target version: master

Summary

Have AdminModel accumulate StreamSocket::getExternalConnectionCount() statistics
in same size and interval as net recv/sent.

The added statistic is rendered into the #NetVisualisation graph using a second y-axis on the right.
Here we use a human-readable quantity tick with added multiple, percentage (1/100) or permyriad (1/10'000) to net::Defaults.maxExtConnections.

Graph is accessible via /browser/dist/admin/adminAnalytics.html#networkview.

Checklist

  • I have run make prettier-write and formatted the code.
  • All commits have Change-Id
  • I have run tests with make check
  • I have issued make run and manually verified that everything looks okay
  • Documentation (manuals or wiki) has been updated or is not required

@sgothel sgothel self-assigned this Nov 9, 2024
@sgothel sgothel added the 24.04 label Nov 9, 2024
@sgothel sgothel force-pushed the private/sgothel/analytics_connections branch from 310d919 to 6e99cc7 Compare November 10, 2024 02:33
@sgothel sgothel changed the title AdminModel (C++/JS): Add (external) connections stats to #NetVisualisation graph Add (external) connections stats to #NetVisualisation graph Nov 10, 2024
@sgothel sgothel force-pushed the private/sgothel/analytics_connections branch from 6e99cc7 to 33328ac Compare November 10, 2024 13:05
@sgothel
Copy link
Author

sgothel commented Nov 11, 2024

Note: The margin to accompany the new right-hand y-axis required some fiddling as I haven't seen utilization of rendered text width (w/ font em size). However, I tested the right margin from like zero to 100% of net::Defaults.maxExtConnections in regards to the tick-label by simply hacking the maximum.
Hope it suits the eyes.

@caolanm caolanm force-pushed the private/sgothel/analytics_connections branch from 33328ac to a90b076 Compare November 11, 2024 19:34
common/Util-desktop.cpp Fixed Show resolved Hide resolved
@sgothel
Copy link
Author

sgothel commented Nov 11, 2024

Cleaned up branch rebased tree, i.e. PR #10375 -> #10455 -> #10456

@caolanm
Copy link
Contributor

caolanm commented Nov 13, 2024

I think here we only need the last patch in this pr, as it seems to build without it and doesn't depend on the others?

@sgothel sgothel force-pushed the private/sgothel/analytics_connections branch from 6fc2bb3 to 4d6f5ee Compare November 13, 2024 13:43
@sgothel sgothel mentioned this pull request Nov 13, 2024
6 tasks
@sgothel
Copy link
Author

sgothel commented Nov 13, 2024

PR #10480 -> #10455 -> #10456

@sgothel sgothel force-pushed the private/sgothel/analytics_connections branch 2 times, most recently from 60f900a to db13f7d Compare November 13, 2024 14:04
@sgothel sgothel requested a review from caolanm November 13, 2024 14:04
@sgothel sgothel force-pushed the private/sgothel/analytics_connections branch from db13f7d to cc5a92b Compare November 13, 2024 14:20
…ation graph

Have AdminModel accumulate StreamSocket::getExternalConnectionCount() statistics
in same size and interval as net recv/sent.

The added statistic is rendered into the #NetVisualisation graph
using a second y-axis on the right.
Here we use a human-readable quantity tick with added multiple, percentage (1/100)
or permyriad (1/10'000) to net::Defaults.maxExtConnections.

Graph is accessible via `/browser/dist/admin/adminAnalytics.html#networkview`.

Signed-off-by: Sven Göthel <sven.gothel@collabora.com>
Change-Id: I614801e7901a23847ea35a2021ecc53a1c000110
@sgothel sgothel force-pushed the private/sgothel/analytics_connections branch from cc5a92b to 390eb76 Compare November 13, 2024 14:51
@sgothel
Copy link
Author

sgothel commented Nov 13, 2024

untangled from #10455

Copy link
Contributor

@mmeeks mmeeks left a comment

Choose a reason for hiding this comment

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

Looks good; can we have a follow-on pure-refactor patch to reduce the code duplication I highlighted.

browser/admin/src/AdminSocketAnalytics.js Show resolved Hide resolved
@mmeeks mmeeks merged commit 574b42a into master Nov 14, 2024
13 checks passed
@mmeeks mmeeks deleted the private/sgothel/analytics_connections branch November 14, 2024 16:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants