-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Adds machine readable conninfo durations #4973
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: R.I.Pienaar <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be opt-in? Should we consider the ability to form shapes by requesting only certain fields?
I am growing concerned watching SCP on NGS deal with the number of connections it already has, and thinking when then goes up multiple orders of magnitude.
Not against making it easier but concerned on longer term impact.
Opt-in doesnt seem like a nice granular approach but for sure being able to extract subsets of fields would be handy. |
The string we use is directly parseable to a time.Duration, but that is in Go of course. |
if thats an API promise then I'll go with that :) |
I think the only place we deviate is in uptime since parse only supports up to hours IIRC. Would need to double check. |
I think we should close if clients can parse ok, as to not add additional weight here to the conninfo. |
OK I will verify it parses correctly then close |
The server use a home-grown encoding format for durations that's hard to use programatically while pleasing to look at - see myUptime() function.
This adds matching time.Duration based ones for machines.
Signed-off-by: R.I.Pienaar [email protected]