Removing deprecated min_pool_size
The database option min_pool_size is not actually used in oslo.db. This is a folllow up to Ib07b7b4200b5cf3a34b8eed441e6754da7d446cf Change-Id: I89754e9e4b42c45259729b0b0bb0a4bf464a981c
This commit is contained in:
parent
57333e902a
commit
6cfdc11ea1
@ -67,17 +67,6 @@ database_opts = [
|
||||
'pool longer than this number of seconds will be replaced '
|
||||
'with a new one the next time they are checked out from '
|
||||
'the pool.'),
|
||||
cfg.IntOpt('min_pool_size',
|
||||
default=1,
|
||||
deprecated_opts=[cfg.DeprecatedOpt('sql_min_pool_size',
|
||||
group='DEFAULT'),
|
||||
cfg.DeprecatedOpt('sql_min_pool_size',
|
||||
group='DATABASE')],
|
||||
deprecated_for_removal=True,
|
||||
deprecated_reason='The option to set the minimum pool '
|
||||
'size is not supported by sqlalchemy.',
|
||||
help='Minimum number of SQL connections to keep open in a '
|
||||
'pool.'),
|
||||
cfg.IntOpt('max_pool_size',
|
||||
default=5,
|
||||
deprecated_opts=[cfg.DeprecatedOpt('sql_max_pool_size',
|
||||
|
@ -181,7 +181,7 @@ class _TransactionFactory(object):
|
||||
(k, _Default(None)) for k in [
|
||||
'db_max_retries', 'db_inc_retry_interval',
|
||||
'use_db_reconnect',
|
||||
'db_retry_interval', 'min_pool_size',
|
||||
'db_retry_interval',
|
||||
'db_max_retry_interval', 'backend', 'use_tpool'])
|
||||
|
||||
self._started = False
|
||||
|
@ -30,7 +30,6 @@ class DbApiOptionsTestCase(test_utils.BaseTestCase):
|
||||
def test_deprecated_session_parameters(self):
|
||||
path = self.create_tempfiles([["tmp", b"""[DEFAULT]
|
||||
sql_connection=x://y.z
|
||||
sql_min_pool_size=10
|
||||
sql_max_pool_size=20
|
||||
sql_max_retries=30
|
||||
sql_retry_interval=40
|
||||
@ -40,7 +39,6 @@ sql_connection_trace=True
|
||||
"""]])[0]
|
||||
self.conf(['--config-file', path])
|
||||
self.assertEqual('x://y.z', self.conf.database.connection)
|
||||
self.assertEqual(10, self.conf.database.min_pool_size)
|
||||
self.assertEqual(20, self.conf.database.max_pool_size)
|
||||
self.assertEqual(30, self.conf.database.max_retries)
|
||||
self.assertEqual(40, self.conf.database.retry_interval)
|
||||
@ -51,7 +49,6 @@ sql_connection_trace=True
|
||||
def test_session_parameters(self):
|
||||
path = self.create_tempfiles([["tmp", b"""[database]
|
||||
connection=x://y.z
|
||||
min_pool_size=10
|
||||
max_pool_size=20
|
||||
max_retries=30
|
||||
retry_interval=40
|
||||
@ -62,7 +59,6 @@ pool_timeout=7
|
||||
"""]])[0]
|
||||
self.conf(['--config-file', path])
|
||||
self.assertEqual('x://y.z', self.conf.database.connection)
|
||||
self.assertEqual(10, self.conf.database.min_pool_size)
|
||||
self.assertEqual(20, self.conf.database.max_pool_size)
|
||||
self.assertEqual(30, self.conf.database.max_retries)
|
||||
self.assertEqual(40, self.conf.database.retry_interval)
|
||||
@ -75,7 +71,6 @@ pool_timeout=7
|
||||
path = self.create_tempfiles([['tmp', b'[DATABASE]\n'
|
||||
b'sql_connection=fake_connection\n'
|
||||
b'sql_idle_timeout=100\n'
|
||||
b'sql_min_pool_size=99\n'
|
||||
b'sql_max_pool_size=199\n'
|
||||
b'sql_max_retries=22\n'
|
||||
b'reconnect_interval=17\n'
|
||||
@ -86,7 +81,6 @@ pool_timeout=7
|
||||
self.assertEqual('fake_connection', self.conf.database.connection)
|
||||
self.assertEqual(100, self.conf.database.connection_recycle_time)
|
||||
self.assertEqual(100, self.conf.database.idle_timeout)
|
||||
self.assertEqual(99, self.conf.database.min_pool_size)
|
||||
self.assertEqual(199, self.conf.database.max_pool_size)
|
||||
self.assertEqual(22, self.conf.database.max_retries)
|
||||
self.assertEqual(17, self.conf.database.retry_interval)
|
||||
|
@ -0,0 +1,7 @@
|
||||
---
|
||||
fixes:
|
||||
- |
|
||||
Removed deprecated database option ``min_pool_size``.
|
||||
|
||||
This option had no effect and was deprecated in Rocky. For more
|
||||
information see bug `1764786 <https://bugs.launchpad.net/oslo.db/+bug/1764786>`_.
|
Loading…
Reference in New Issue
Block a user