Repository navigation
Commit 9b05f90
committed
```text
xds: implement separate request and response draining in ExternalProcessorServerInterceptor
Update ExternalProcessorServerInterceptor to support separate request-side
and response-side draining per the updated gRFC and Envoy ext_proc proto:
- Replace the unified DRAINING stream state with directional draining
and pass-through state (requestDraining, requestDrainComplete,
responseDraining, responseDrainComplete, requestPassThrough, and
passThroughMode).
- Split flow-control readiness into isRequestSidecarReady() and
isResponseSidecarReady() so draining one direction does not block or
prematurely unblock the other direction.
- Implement the two-way drain_complete body handshake for request and
response streams when body processing is configured, and ignore drain
requests after end_of_stream has already been sent for that direction.
- Close the ext_proc stream once both directions have completed draining
(in non-observability mode), and treat premature OK termination from
ext_proc before both directions are drained or at EOS as an error.
- Update existing server interceptor draining tests and add unit tests
for directional draining and EOS edge cases.
TAG=agy
CONV=2c1e4760-c239-4698-810a-162bf10fccc4
```1 parent 4c385cc commit 9b05f90
3 files changed
Lines changed: 1262 additions & 315 deletions
File tree
- xds
- src
- main/java/io/grpc/xds
- test/java/io/grpc/xds
- third_party/envoy/src/main/proto/envoy/service/ext_proc/v3
0 commit comments