Merge "Switch from MySQL-python to PyMySQL"

This commit is contained in:
Jenkins 2015-06-04 09:44:04 +00:00 committed by Gerrit Code Review
commit 6a4769a70f

View File

@ -57,7 +57,8 @@ class ControlDriver(storage.ControlDriverBase):
sa.event.listen(engine, 'connect',
self._sqlite_on_connect)
if uri.startswith('mysql://'):
if (uri.startswith('mysql+pymysql://')
or uri.startswith('mysql://')):
sa.event.listen(engine, 'connect',
self._mysql_on_connect)