diff options
author | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2014-02-28 11:25:40 -0500 |
---|---|---|
committer | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2014-02-28 11:25:41 -0500 |
commit | ab3748ee1bdc3ed85fc721dbfb73cf82bdccdda9 (patch) | |
tree | d2744c3d7eab39752898223719ac57ac03d08bdf /src/lib/Bcfg2/Reporting/Collector.py | |
parent | 12edf6186b236006963b83ac8ffe174665e097b9 (diff) | |
download | bcfg2-ab3748ee1bdc3ed85fc721dbfb73cf82bdccdda9.tar.gz bcfg2-ab3748ee1bdc3ed85fc721dbfb73cf82bdccdda9.tar.bz2 bcfg2-ab3748ee1bdc3ed85fc721dbfb73cf82bdccdda9.zip |
Reporting: properly close db connection
Close the db connection at the end of each DjangoORM import, not when
the reporting collector shuts down. The collector may not have even
opened a connection, in the case of a storage backend other than
DjangoORM.
Diffstat (limited to 'src/lib/Bcfg2/Reporting/Collector.py')
-rw-r--r-- | src/lib/Bcfg2/Reporting/Collector.py | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/src/lib/Bcfg2/Reporting/Collector.py b/src/lib/Bcfg2/Reporting/Collector.py index 0493c907b..2859eca28 100644 --- a/src/lib/Bcfg2/Reporting/Collector.py +++ b/src/lib/Bcfg2/Reporting/Collector.py @@ -162,9 +162,6 @@ class ReportingCollector(object): pass if self.storage: self.storage.shutdown() - from django import db - self.logger.info("%s: Closing database connection" % self.name) - db.close_connection() def reap_children(self): """Join any non-live threads""" |