Fix mysql connection
URL mysql://scott:***@some_host/some_db does not contain a '+drivername' portion, and will make use of a default driver. A full dbname+drivername:// protocol is recommended. For MySQL, it is strongly recommended that mysql+pymysql:// be specified for maximum service compatibility. Change-Id: Ib5cbfcc412c04381f2fce9f319a313eb86ea7fa8 Closes-Bug: #1753342
This commit is contained in:
parent
e985087545
commit
76bce0ada4
@ -13,7 +13,7 @@
|
||||
#
|
||||
# [*database_connection*]
|
||||
# (Optional) Url used to connect to database.
|
||||
# Defaults to 'mysql://ceilometer:ceilometer@localhost/ceilometer'.
|
||||
# Defaults to 'mysql+pymysql://ceilometer:ceilometer@localhost/ceilometer'.
|
||||
#
|
||||
# [*database_idle_timeout*]
|
||||
# (Optional) Timeout when db connections should be reaped.
|
||||
@ -46,7 +46,7 @@
|
||||
#
|
||||
class ceilometer::db (
|
||||
$database_db_max_retries = $::os_service_default,
|
||||
$database_connection = 'mysql://ceilometer:ceilometer@localhost/ceilometer',
|
||||
$database_connection = 'mysql+pymysql://ceilometer:ceilometer@localhost/ceilometer',
|
||||
$database_idle_timeout = $::os_service_default,
|
||||
$database_min_pool_size = $::os_service_default,
|
||||
$database_max_pool_size = $::os_service_default,
|
||||
|
@ -10,7 +10,7 @@ describe 'ceilometer::db' do
|
||||
it { is_expected.to contain_class('ceilometer::db::sync') }
|
||||
it { is_expected.to contain_oslo__db('ceilometer_config').with(
|
||||
:db_max_retries => '<SERVICE DEFAULT>',
|
||||
:connection => 'mysql://ceilometer:ceilometer@localhost/ceilometer',
|
||||
:connection => 'mysql+pymysql://ceilometer:ceilometer@localhost/ceilometer',
|
||||
:idle_timeout => '<SERVICE DEFAULT>',
|
||||
:min_pool_size => '<SERVICE DEFAULT>',
|
||||
:max_pool_size => '<SERVICE DEFAULT>',
|
||||
|
Loading…
Reference in New Issue
Block a user