diff --git a/sdks/python/apache_beam/io/requestresponse.py b/sdks/python/apache_beam/io/requestresponse.py index 9fdf33e2299d..0677efbac000 100644 --- a/sdks/python/apache_beam/io/requestresponse.py +++ b/sdks/python/apache_beam/io/requestresponse.py @@ -375,7 +375,8 @@ def process(self, request: RequestT, *args, **kwargs): response = self._repeater.repeat( self._caller, request, self._timeout, self._metrics_collector) self._metrics_collector.responses.inc(1) - self._throttler.throttler.successful_request(req_time * MSEC_TO_SEC) + if self._throttler: + self._throttler.throttler.successful_request(req_time * MSEC_TO_SEC) yield response except Exception as e: raise e