I have seen many posts about the QueuePool limit but I really don't know 
how to solve it in my code.

The error is: *TimeoutError: QueuePool limit of size 5 overflow 10 reached, 
connection timed out, timeout 30*

I start one unique session in the __init__.py like this:

    
engine = create_engine("mysql://" + loadConfigVar("user") + ":" + 
loadConfigVar("password") + "@" + loadConfigVar("host") + "/" + 
loadConfigVar("schema"))

    #Sets the engine to the session and the Base model class
    DBSession.configure(bind=engine)



Then in subsequent code I use it like this:

   
from .dbmodels import DBSession 
transaction.commit()
    rescount = DBSession.connection().execute("select 
resource_id,count(resource_id) as total FROM resourcestats")

DBSession is defined like:

DBSession = scoped_session(sessionmaker(extension=ZopeTransactionExtension
()))



Does the execution of an SQL increases the pool limit? Or what you reckon 
is going on?

Thanks,
Carlos.

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sqlalchemy+unsubscr...@googlegroups.com.
To post to this group, send email to sqlalchemy@googlegroups.com.
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/d/optout.

Reply via email to