Repository navigation
chore(gateway): propagate request context in webRequestT - #6694
Conversation
|
Hi @atzoum , Testing : Please let me know if there is any changes for enhancement. Thank You! |
…miter and downstream components respect request cancellations.
… avoid stat increments on dropped connections and add tests.
e1d33ec to
4d64f83
Compare
🔒 Scanned for secrets using gitleaks 8.30.0
|
@akshit-git24 tests are failing package=gateway make test |
|
@akshit-git24 I closed this pr by mistake, please open a new one |
Description
This PR fixes an issue where aggregate/batch requests in
webRequestTwere losing the original HTTP request context.Previously,
webRequestTdid not store the context, causing the rate limiter and other downstream consumers to usecontext.TODO(). This prevented the gateway from respecting request cancellations and timeouts.Changes:
ctx context.Contextto thewebRequestTstruct.addToWebRequestQingateway/handle.goto capturereq.Context().getJobDataFromRequest(consumer) to pass the propagatedctxtogw.rateLimiter.CheckLimitReached.Security