From a1dffa6a7f61fe73831f61d11120cc5396c348b4 Mon Sep 17 00:00:00 2001 From: Abolfazl Date: Mon, 4 May 2026 08:42:35 +0330 Subject: [PATCH] fix: route exit-node requests through batch collector instead of bypassing it --- src/relay/domain_fronter.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/relay/domain_fronter.py b/src/relay/domain_fronter.py index 7685ae1..29f737b 100644 --- a/src/relay/domain_fronter.py +++ b/src/relay/domain_fronter.py @@ -1231,8 +1231,10 @@ class DomainFronter: payload.get("u", "")[:60], ) - # Send through the normal Apps Script relay path (H2 or H1 + retry) - raw = await self._relay_with_retry(outer) + # Send through the batch collector so exit-node requests are coalesced + # into fetchAll() alongside other concurrent requests, reducing Apps + # Script quota usage. _relay_with_retry bypasses batching entirely. + raw = await self._batch_submit(outer) # raw is now the response from the exit node (inner relay JSON) # _parse_relay_response will decode it into the final HTTP response.