Return errors from Connection
methods to the Client
#4734
Labels
A-network
Area: Network protocol updates or fixes
C-security
Category: Security issues
I-panic
Zebra panics with an internal error message
Motivation
We're seeing "failed servers must set their error slot" panics when Zebra is overloaded.
This panic is caused by the design of the
Client
connection code. Currently, theClient
tasks share anErrorSlot
mutex, which must be updated before they exit.This ticket stops using the error slot in the
Connection
task.Designs
Instead of using the error slot,
Client
tasks should exit and return an error to the client instance.The
Client
should exit when any task errors or stops.We could try something like this:
(click for details)
Replace
Connection.error_slot
with returning aPeerError
:Connection
methodConnection::run
break
from the run loop, callshutdown
, then return the errorJoinHandle
in theClient
Related Work
This is part of:
The text was updated successfully, but these errors were encountered: