Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DB connection gives Quepool limit exceeded when run with TaskIQ #368

Open
SifatHasnain opened this issue Sep 27, 2024 · 0 comments
Open

Comments

@SifatHasnain
Copy link

Screenshot from 2024-09-28 00-40-35
I am using ListQueueBroker from taskiq-redis. The task I am running handles database queries with Python SqlAlchemy (Postgresql).
The same task when running in the background for even 1000 times, the system does not break. But with TaskIQ I am getting this timeout error saying QueuePool limit is exceeded. The configuration I am using for the DB connection is
engine = create_async_engine(
DB_URI,
poolclass=AsyncAdaptedQueuePool,
pool_size=int(os.environ.get("DB_POOL_SIZE", 10)),
max_overflow=int(os.environ.get("DB_MAX_OVERFLOW", 10)),
pool_pre_ping=True,
pool_recycle=3600,
pool_timeout=20,
)

I have tried increasing the values but even with 30 tasks the system breaks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant