mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-07-20 02:31:02 +02:00
Renamed retry_count to rate_limit_count
This commit is contained in:
parent
f2a8ebb21f
commit
24ef170797
1 changed files with 4 additions and 4 deletions
|
|
@ -54,9 +54,9 @@ class Consumer(BaseProcessor):
|
||||||
'processing_count', 'Processing count', ["status"]
|
'processing_count', 'Processing count', ["status"]
|
||||||
)
|
)
|
||||||
|
|
||||||
if not hasattr(__class__, "retry_metric"):
|
if not hasattr(__class__, "rate_limit_metric"):
|
||||||
__class__.retry_metric = Counter(
|
__class__.rate_limit_metric = Counter(
|
||||||
'retry_count', 'Retry count',
|
'rate_limit_count', 'Rate limit event count',
|
||||||
)
|
)
|
||||||
|
|
||||||
__class__.pubsub_metric.info({
|
__class__.pubsub_metric.info({
|
||||||
|
|
@ -118,7 +118,7 @@ class Consumer(BaseProcessor):
|
||||||
|
|
||||||
print("TooManyRequests: will retry...", flush=True)
|
print("TooManyRequests: will retry...", flush=True)
|
||||||
|
|
||||||
__class__.retry_metric.inc()
|
__class__.rate_limit_metric.inc()
|
||||||
|
|
||||||
# Sleep
|
# Sleep
|
||||||
time.sleep(self.rate_limit_retry)
|
time.sleep(self.rate_limit_retry)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue