[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Maposmatic-dev] [PATCH] Display database connection information in the
From: |
Maxime Petazzoni |
Subject: |
[Maposmatic-dev] [PATCH] Display database connection information in the daemon log |
Date: |
Thu, 7 Jan 2010 09:29:42 +0100 |
This makes things easier when debugging the setting up of the rendering
pipeline with the MapOSMatic daemon and PostgreSQL.
---
ocitysmap/street_index.py | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/ocitysmap/street_index.py b/ocitysmap/street_index.py
index 50d8c1a..9d2e8c2 100644
--- a/ocitysmap/street_index.py
+++ b/ocitysmap/street_index.py
@@ -291,9 +291,12 @@ class OCitySMap:
datasource = dict(self.parser.items('datasource'))
- db = pgdb.connect('Notre Base', datasource['user'],
- datasource['password'], datasource['host'],
- datasource['dbname'])
+ LOG.info('Connecting to database %s at %s (user: %s)...' %
+ (datasource['dbname'], datasource['host'],
datasource['user']))
+ db = pgdb.connect(user=datasource['user'],
+ password=datasource['password'],
+ host=datasource['host'],
+ database=datasource['dbname'])
# Set session timeout parameter (18mn)
cursor = db.cursor()
--
1.6.3.3.261.g85c6
- [Maposmatic-dev] [PATCH] Display database connection information in the daemon log,
Maxime Petazzoni <=