From 45141172153d8c7585dca1e3c9b0cd5836231614 Mon Sep 17 00:00:00 2001 From: Andrew Ruthven Date: Mon, 22 Jun 2009 21:23:12 +1200 Subject: [PATCH] Switch from pyPgSQL.PgSQL to pyscopg2. --- controller-service | 2 +- services/master/database.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/controller-service b/controller-service index 899053a..ec7159a 100755 --- a/controller-service +++ b/controller-service @@ -37,7 +37,7 @@ import services.config as config class Controller(pb.Root): def service_setup(self): - self.connection_type = "pyPgSQL.PgSQL" + self.connection_type = "psycopg2" self.connection_dict = dict(cp_reconnect=True, host=config.get("db", "host"), user=config.get("db", "user"), diff --git a/services/master/database.py b/services/master/database.py index ab7c7eb..f78bea0 100644 --- a/services/master/database.py +++ b/services/master/database.py @@ -55,7 +55,7 @@ class DatabaseManager: Start up the connection to the database. """ if self.db is None: - self.db = adbapi.ConnectionPool("pyPgSQL.PgSQL", cp_reconnect=True, + self.db = adbapi.ConnectionPool("psycopg2", cp_reconnect=True, host=config.get("db", "host"), user=config.get("db", "user"), password=config.get("db", "passwd"), -- 2.30.2