Explorar el Código

increase pool size of Postgresql

highing666 hace 3 años
padre
commit
e16dbe752e
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      app/db/session.py

+ 1 - 1
app/db/session.py

@@ -4,7 +4,7 @@ from sqlalchemy.orm import sessionmaker
 
 from app.core.config import settings
 
-engine = create_engine(settings.SQLALCHEMY_DATABASE_URL, pool_pre_ping=True, pool_size=90)
+engine = create_engine(settings.SQLALCHEMY_DATABASE_URL, pool_pre_ping=True, pool_size=1000, max_overflow=2000)
 SessionLocal = sessionmaker(autocommit=False, autoflush=False, bind=engine)
 
 Base = declarative_base()