-
-
Notifications
You must be signed in to change notification settings - Fork 145
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
fix(console): fix the issue of continuous reconnection caused by decode failure #500
Conversation
…de failure Signed-off-by: Wenbo Zhang <wenbo.zhang@iomesh.com>
I hit the same error and your patch fixes it. I can connect to my server shortly after it starts, but if I wait a few minutes before connecting I start seeing that log message and tokio-console won't work. Thanks! UPDATE: The fix only buys some time but doesn't solve the problem. I eventually got to:
Not sure if it's my app or tokio-console. My guess is it's console-subscriber. |
Thank you for the information. Maybe we also need to limit the size of encoding. I will do further research to confirm. |
@grahamking From https://github.com/hyperium/tonic/blob/v0.10.2/tonic/src/lib.rs#L62 it says:
So I think we need to call |
I don't have very many tasks, maybe 20 per second at most, they are short lived. I think the issue is that when a client first connects it gets an Reducing retention to 1 minute prevents the problem, but then I get a different issue where nothing updates in the tokio-console display. Still trying to figure that one out. |
Oh I see, indeed, keeping 1h by default consumes a lot of memory. |
Do not record poll_ops if there are no current connected clients (watchers). Without this `Aggregator::poll_ops` would grow forever. Follow up to tokio-rs#311 and fix for these two: - tokio-rs#184 - tokio-rs#500
I think I hit two overlapping problems:
|
Do not record poll_ops if there are no current connected clients (watchers). Without this `Aggregator::poll_ops` would grow forever. Follow up to #311 and fix for these two: - #184 - #500 Fixes #184 Co-authored-by: Graham King <grahamk@nvidia.com> Co-authored-by: Hayden Stainsby <hds@caffeineconcepts.com>
By default, both of the
tonic
'smax_decoding_message_size
is4M
, when there are too many async tasks, the decoding will over4M
, causingtokio-console
decoding to fail.When it fails, the
tokio-console
interface will continuously displayConnected/Reconnect
, as it may be a bit strange to make thedecoding maximum value
a command line parameter, so make it16M
as aconst value
.