From: Evan Broder Date: Sun, 5 Oct 2008 03:23:10 +0000 (-0400) Subject: Re-establish the database connection if the server goes AWOL X-Git-Tag: sipb-xen-database/10.28^0 X-Git-Url: http://xvm.mit.edu/gitweb/invirt/packages/invirt-database.git/commitdiff_plain/7e25fbcc4c76eb8f67341ff82b47e875f0243280 Re-establish the database connection if the server goes AWOL svn path=/trunk/packages/sipb-xen-database/; revision=1041 --- diff --git a/debian/changelog b/debian/changelog index 74ab33d..2af5b40 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +sipb-xen-database (10.28) unstable; urgency=low + + * Re-establish the database connection if the server goes AWOL + + -- Evan Broder Sat, 04 Oct 2008 23:19:59 -0400 + sipb-xen-database (10.27) unstable; urgency=low * Update sipb-database to work with newer SQLAlchemy and Xen diff --git a/python/database/__init__.py b/python/database/__init__.py index 258c4d4..b3dd61c 100644 --- a/python/database/__init__.py +++ b/python/database/__init__.py @@ -4,6 +4,6 @@ import sqlalchemy def connect(uri = config.db.uri): """ Connect to a given database URI""" - engine = sqlalchemy.create_engine(uri) + engine = sqlalchemy.create_engine(uri, pool_timeout=5) meta.bind = engine session.configure(bind=engine)