Merge "fix session connection"

This commit is contained in:
Jenkins 2013-06-11 18:28:40 +00:00 committed by Gerrit Code Review
commit 74c6b25b72
3 changed files with 2 additions and 4 deletions

View File

@ -57,7 +57,8 @@ def register_opts(conf):
def get_engine(conf): def get_engine(conf):
"""Load the configured engine and return an instance.""" """Load the configured engine and return an instance."""
if conf.database_connection: if conf.database_connection:
conf.database.connection = conf.database_connection conf.set_override('connection', conf.database_connection,
group='database')
engine_name = urlparse.urlparse(conf.database.connection).scheme engine_name = urlparse.urlparse(conf.database.connection).scheme
LOG.debug('looking for %r driver in %r', LOG.debug('looking for %r driver in %r',
engine_name, STORAGE_ENGINE_NAMESPACE) engine_name, STORAGE_ENGINE_NAMESPACE)

View File

@ -322,7 +322,6 @@ class Connection(base.Connection):
# a new key '_id'). # a new key '_id').
record = copy.copy(data) record = copy.copy(data)
self.db.meter.insert(record) self.db.meter.insert(record)
return
def get_users(self, source=None): def get_users(self, source=None):
"""Return an iterable of user id strings. """Return an iterable of user id strings.

View File

@ -212,8 +212,6 @@ class Connection(base.Connection):
meter.message_id = data['message_id'] meter.message_id = data['message_id']
session.flush() session.flush()
return
def get_users(self, source=None): def get_users(self, source=None):
"""Return an iterable of user id strings. """Return an iterable of user id strings.