Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions vectordb_bench/backend/runner/concurrent_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class ConcurrentInsertRunner:
normalize: Whether to L2-normalize embeddings.
filters: Filter configuration.
timeout: Timeout in seconds for the overall operation.
max_workers: Number of concurrent workers (default: cpu_count).
max_workers: Number of concurrent workers (default: min(cpu_count, 4)).
backend: Executor backend to use ('threading' or 'async').
"""

Expand All @@ -72,7 +72,7 @@ def __init__(
self.filters = filters
self.backend = backend

effective_workers = max_workers or mp.cpu_count()
effective_workers = max_workers or min(mp.cpu_count(), 4)
if not db.thread_safe:
log.info(f"DB {db.name} is not thread-safe, falling back to max_workers=1")
effective_workers = 1
Expand Down
Loading