summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.zuul.yaml5
-rw-r--r--keystonemiddleware/auth_token/_cache.py9
-rw-r--r--keystonemiddleware/auth_token/_opts.py5
-rw-r--r--lower-constraints.txt6
-rw-r--r--releasenotes/notes/deprecate-eventlet-unsafe-memcacheclientpool-f8b4a6733513d73e.yaml22
-rw-r--r--releasenotes/source/locale/en_GB/LC_MESSAGES/releasenotes.po7
-rw-r--r--test-requirements.txt2
7 files changed, 45 insertions, 11 deletions
diff --git a/.zuul.yaml b/.zuul.yaml
index d8d3842..b0ecfd1 100644
--- a/.zuul.yaml
+++ b/.zuul.yaml
@@ -1,9 +1,12 @@
- project:
templates:
- openstack-cover-jobs
- - openstack-lower-constraints-jobs
- openstack-python3-ussuri-jobs
- publish-openstack-docs-pti
- check-requirements
- lib-forward-testing-python3
- release-notes-jobs-python3
+ check:
+ jobs:
+ - openstack-tox-lower-constraints:
+ voting: false
diff --git a/keystonemiddleware/auth_token/_cache.py b/keystonemiddleware/auth_token/_cache.py
index 8951b37..94aa7cd 100644
--- a/keystonemiddleware/auth_token/_cache.py
+++ b/keystonemiddleware/auth_token/_cache.py
@@ -124,7 +124,7 @@ class TokenCache(object):
def __init__(self, log, cache_time=None,
env_cache_name=None, memcached_servers=None,
- use_advanced_pool=False, dead_retry=None, socket_timeout=None,
+ use_advanced_pool=True, dead_retry=None, socket_timeout=None,
**kwargs):
self._LOG = log
self._cache_time = cache_time
@@ -150,6 +150,13 @@ class TokenCache(object):
**self._memcache_pool_options)
else:
+ if not self._use_advanced_pool:
+ self._LOG.warning(
+ "Using the eventlet-unsafe cache pool is deprecated."
+ "It is recommended to use eventlet-safe cache pool"
+ "implementation from oslo.cache. This can be enabled"
+ "through config option memcache_use_advanced_pool = True")
+
return _CachePool(self._memcached_servers, self._LOG)
def initialize(self, env):
diff --git a/keystonemiddleware/auth_token/_opts.py b/keystonemiddleware/auth_token/_opts.py
index 15dd4f6..1ddef7d 100644
--- a/keystonemiddleware/auth_token/_opts.py
+++ b/keystonemiddleware/auth_token/_opts.py
@@ -145,10 +145,9 @@ _OPTS = [
help='(Optional) Number of seconds that an operation will wait '
'to get a memcached client connection from the pool.'),
cfg.BoolOpt('memcache_use_advanced_pool',
- default=False,
+ default=True,
help='(Optional) Use the advanced (eventlet safe) memcached '
- 'client pool. The advanced pool will only work under '
- 'python 2.x.'),
+ 'client pool.'),
cfg.BoolOpt('include_service_catalog',
default=True,
help='(Optional) Indicate whether to set the X-Service-Catalog'
diff --git a/lower-constraints.txt b/lower-constraints.txt
index 8fd4ac7..7cf2eef 100644
--- a/lower-constraints.txt
+++ b/lower-constraints.txt
@@ -4,12 +4,12 @@ Babel==2.5.3
bandit==1.1.0
beautifulsoup4==4.6.0
certifi==2018.1.18
-cffi==1.11.5
+cffi==1.14.0
chardet==3.0.4
cliff==2.11.0
cmd2==0.8.1
coverage==4.0
-cryptography==2.1
+cryptography==3.0
debtcollector==1.19.0
dogpile.cache==0.6.5
dulwich==0.19.0
@@ -62,7 +62,7 @@ python-memcached==1.59
python-mimeparse==1.6.0
python-subunit==1.2.0
pytz==2018.3
-PyYAML==3.12
+PyYAML==3.13
requests-mock==1.2.0
requests==2.14.2
requestsexceptions==1.4.0
diff --git a/releasenotes/notes/deprecate-eventlet-unsafe-memcacheclientpool-f8b4a6733513d73e.yaml b/releasenotes/notes/deprecate-eventlet-unsafe-memcacheclientpool-f8b4a6733513d73e.yaml
new file mode 100644
index 0000000..2269994
--- /dev/null
+++ b/releasenotes/notes/deprecate-eventlet-unsafe-memcacheclientpool-f8b4a6733513d73e.yaml
@@ -0,0 +1,22 @@
+---
+deprecations:
+ - |
+ We no longer recommend using the eventlet unsafe keystonemiddleware's
+ memcacheclientpool. This implementation may result in growing connections
+ to memcached.
+
+ It is recommended that the ``memcache_use_advanced_pool`` option
+ is set to ``True`` in the ``keystone_authtoken`` configuration section of
+ the various services (e.g. nova, glance, ...) when memcached is used for
+ token cache.
+upgrade:
+ - |
+ [`bug 1892852 <https://bugs.launchpad.net/keystonemiddleware/+bug/1892852>`_]
+ [`bug 1888394 <https://bugs.launchpad.net/oslo.cache/+bug/1888394>`_]
+ [`bug 1883659 <https://bugs.launchpad.net/keystonemiddleware/+bug/1883659>`_]
+ Keystonemiddleware now using eventlet-safe implementation of
+ ``MemcacheClientPool`` from oslo.cache's library by default.
+ The ``keystonemiddleware`` implementation is now deprecated. For backwards
+ compatibility, the ``[keystone_authtoken] memcache_use_advanced_pool``
+ option can be set to ``False`` config files of the various services (e.g.
+ nova, glance, ...) when memcached is used for token cache.
diff --git a/releasenotes/source/locale/en_GB/LC_MESSAGES/releasenotes.po b/releasenotes/source/locale/en_GB/LC_MESSAGES/releasenotes.po
index 56b9910..4fb79f2 100644
--- a/releasenotes/source/locale/en_GB/LC_MESSAGES/releasenotes.po
+++ b/releasenotes/source/locale/en_GB/LC_MESSAGES/releasenotes.po
@@ -6,11 +6,11 @@ msgid ""
msgstr ""
"Project-Id-Version: keystonemiddleware\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2020-06-05 04:54+0000\n"
+"POT-Creation-Date: 2021-03-02 18:48+0000\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"PO-Revision-Date: 2020-06-15 05:35+0000\n"
+"PO-Revision-Date: 2020-10-28 02:17+0000\n"
"Last-Translator: Andi Chandler <andi@gowling.com>\n"
"Language-Team: English (United Kingdom)\n"
"Language: en_GB\n"
@@ -44,6 +44,9 @@ msgstr "4.20.0"
msgid "4.22.0"
msgstr "4.22.0"
+msgid "4.22.0-2"
+msgstr "4.22.0-2"
+
msgid "4.3.0"
msgstr "4.3.0"
diff --git a/test-requirements.txt b/test-requirements.txt
index c6d68d6..cd0bfc9 100644
--- a/test-requirements.txt
+++ b/test-requirements.txt
@@ -6,7 +6,7 @@ hacking>=3.0,<4.0.0 # Apache-2.0
flake8-docstrings==0.2.1.post1 # MIT
coverage!=4.4,>=4.0 # Apache-2.0
-cryptography>=2.1 # BSD/Apache-2.0
+cryptography>=3.0 # BSD/Apache-2.0
fixtures>=3.0.0 # Apache-2.0/BSD
oslotest>=3.2.0 # Apache-2.0
requests-mock>=1.2.0 # Apache-2.0