Skip to content

Commit

Permalink
improve: Added 5 seconds wait before retry
Browse files Browse the repository at this point in the history
  • Loading branch information
hh-space-invader committed Nov 12, 2024
1 parent 213a978 commit 25d452d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion qdrant_client/uploader/grpc_uploader.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import time
import logging
from itertools import count
from typing import Any, Generator, Iterable, Optional, Tuple, Union
Expand Down Expand Up @@ -48,7 +49,7 @@ def upload_batch_grpc(
break
except Exception as e:
logging.warning(f"Batch upload failed {attempt + 1} times. Retrying...")

time.sleep(5)
if attempt == max_retries - 1:
raise e
return True
Expand Down

0 comments on commit 25d452d

Please sign in to comment.