You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add ability to drain the listeners using the admin interface #4460
Title: Add ability to drain the listeners using the admin interface
Description:
Drain the listeners on demand, with the assumption that we're going to shutdown shortly afterwards, so future updates to those listeners should be ignored.
@PiotrSikora I haven't explored this part deeply, but isn't this supposed to be the desired effect of "/quitquitquit" or is that behavior more synonymous with "/abortabortabort" ?
@cmluciano it's the first half of /quitquitquit, really. The major use case for use would be to stop accepting incoming connections when acting as a sidecar, but still let the application to make outgoing connections (see #4461).
I think this is related to our need for per-listener shutdown - we run a single shared envoy per host instead of one-per-pod. If (our equivalent of) a pod is going down, we want to be able to just shut down that ingress listener. We do this today with our healthcheck cache , but we'll want to do this with Envoy in the future.
I think this might actually make the implementation easier, since if you had per-listener control, i presume that you could just drain the ingress listener but still keep the egress listener alive.
This issue has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in the next 7 days unless it is tagged "help wanted" or other activity occurs. Thank you for your contributions.
This issue has been automatically closed because it has not had activity in the last 37 days. If this issue is still valid, please ping a maintainer and ask them to label it as "help wanted". Thank you for your contributions.
@mattklein123 We are interested in this feature. Just want to understand at a high level if the following is sufficient
add a admin endpoint /drain_listeners that drains all listeners.
add additional parameter like /drain_listeners?inboundonly - will drain only inbound listeners because that is what most people would want when a rolling upgrade happens because incoming connection should be stopped while inflight work should continue which may use outbound listeners. Since traffic direction is added to listener now - we can easily distinguish inbound/outbound listeners.
Wonder if the ?inboundonly parameter could be added to /healthcheck/fail as well, to also initiate draining for inbound listeners only, but without rejecting new connections. What do you think?
Activity
ramaraochavali commentedon Sep 19, 2018
It may be useful/partial solution to address this issue as well istio/istio#7665
cmluciano commentedon Sep 19, 2018
@PiotrSikora I haven't explored this part deeply, but isn't this supposed to be the desired effect of "/quitquitquit" or is that behavior more synonymous with "/abortabortabort" ?
mattklein123 commentedon Sep 19, 2018
This should be pretty easily doable by allowing programmatic access to the existing drain functionality that is kicked off as part of hot restart.
PiotrSikora commentedon Sep 19, 2018
@cmluciano it's the first half of
/quitquitquit, really. The major use case for use would be to stop accepting incoming connections when acting as a sidecar, but still let the application to make outgoing connections (see #4461).bplotnick commentedon Sep 19, 2018
I think this is related to our need for per-listener shutdown - we run a single shared envoy per host instead of one-per-pod. If (our equivalent of) a pod is going down, we want to be able to just shut down that ingress listener. We do this today with our healthcheck cache , but we'll want to do this with Envoy in the future.
I think this might actually make the implementation easier, since if you had per-listener control, i presume that you could just drain the ingress listener but still keep the egress listener alive.
stale commentedon Oct 20, 2018
This issue has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in the next 7 days unless it is tagged "help wanted" or other activity occurs. Thank you for your contributions.
stale commentedon Oct 27, 2018
This issue has been automatically closed because it has not had activity in the last 37 days. If this issue is still valid, please ping a maintainer and ask them to label it as "help wanted". Thank you for your contributions.
ramaraochavali commentedon Sep 26, 2019
@mattklein123 We are interested in this feature. Just want to understand at a high level if the following is sufficient
/drain_listenersthat drains all listeners./drain_listeners?inboundonly- will drain only inbound listeners because that is what most people would want when a rolling upgrade happens because incoming connection should be stopped while inflight work should continue which may use outbound listeners. Since traffic direction is added to listener now - we can easily distinguish inbound/outbound listeners.What do you think about that approach?
mattklein123 commentedon Sep 26, 2019
@ramaraochavali this sounds good to me. I think you could later also add a query param to even drain by name, etc.
ramaraochavali commentedon Sep 27, 2019
/assign @ramaraochavali
deiwin commentedon Feb 7, 2020
Wonder if the
?inboundonlyparameter could be added to/healthcheck/failas well, to also initiate draining for inbound listeners only, but without rejecting new connections. What do you think?