keystone  18.0.0
About: OpenStack Keystone (Core Service: Identity) provides an authentication and authorization service for other OpenStack services. Provides a catalog of endpoints for all OpenStack services.
The "Victoria" series (maintained release).
  Fossies Dox: keystone-18.0.0.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

memcache.py
Go to the documentation of this file.
1 # Licensed under the Apache License, Version 2.0 (the "License"); you may
2 # not use this file except in compliance with the License. You may obtain
3 # a copy of the License at
4 #
5 # http://www.apache.org/licenses/LICENSE-2.0
6 #
7 # Unless required by applicable law or agreed to in writing, software
8 # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
9 # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
10 # License for the specific language governing permissions and limitations
11 # under the License.
12 
13 from oslo_config import cfg
14 from oslo_log import versionutils
15 
16 from keystone.conf import utils
17 
18 
19 dead_retry = cfg.IntOpt(
20  'dead_retry',
21  default=5 * 60,
22  help=utils.fmt("""
23 Number of seconds memcached server is considered dead before it is tried again.
24 This is used by the key value store system.
25 """))
26 
27 socket_timeout = cfg.IntOpt(
28  'socket_timeout',
29  default=3,
30  deprecated_for_removal=True,
31  deprecated_reason='This option is duplicated with oslo.cache. '
32  'Configure ``keystone.conf [cache] '
33  'memcache_socket_timeout`` option to set the '
34  'socket_timeout of memcached instead. ',
35  deprecated_since=versionutils.deprecated.TRAIN,
36  help=utils.fmt("""
37 Timeout in seconds for every call to a server. This is used by the key value
38 store system.
39 """))
40 
41 pool_maxsize = cfg.IntOpt(
42  'pool_maxsize',
43  default=10,
44  help=utils.fmt("""
45 Max total number of open connections to every memcached server. This is used by
46 the key value store system.
47 """))
48 
49 pool_unused_timeout = cfg.IntOpt(
50  'pool_unused_timeout',
51  default=60,
52  help=utils.fmt("""
53 Number of seconds a connection to memcached is held unused in the pool before
54 it is closed. This is used by the key value store system.
55 """))
56 
57 pool_connection_get_timeout = cfg.IntOpt(
58  'pool_connection_get_timeout',
59  default=10,
60  help=utils.fmt("""
61 Number of seconds that an operation will wait to get a memcache client
62 connection. This is used by the key value store system.
63 """))
64 
65 
66 GROUP_NAME = __name__.split('.')[-1]
67 ALL_OPTS = [
68  dead_retry,
69  socket_timeout,
70  pool_maxsize,
71  pool_unused_timeout,
72  pool_connection_get_timeout,
73 ]
74 
75 
76 def register_opts(conf):
77  conf.register_opts(ALL_OPTS, group=GROUP_NAME)
78 
79 
80 def list_opts():
81  return {GROUP_NAME: ALL_OPTS}
keystone.conf.memcache.register_opts
def register_opts(conf)
Definition: memcache.py:76
keystone.conf.memcache.list_opts
def list_opts()
Definition: memcache.py:80
keystone.conf
Definition: __init__.py:1