From 85234209307e5917be40ca78342617d003429858 Mon Sep 17 00:00:00 2001 From: Juan Antonio Osorio Robles Date: Mon, 30 Oct 2017 10:00:49 +0200 Subject: [PATCH] Make memcached logs verbosity configurable This adds the MemcachedDebug flag which makes memcached logs verbose. Also, the service now reacts to the global Debug flag. Related-Bug: #1720183 Change-Id: Ie8120359a12f734aad584b083c8362dd21b70dea --- puppet/services/memcached.yaml | 24 ++++++++++++++++++- ...mcached-verbose-logs-84ca938d76c16429.yaml | 6 +++++ 2 files changed, 29 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/memcached-verbose-logs-84ca938d76c16429.yaml diff --git a/puppet/services/memcached.yaml b/puppet/services/memcached.yaml index 30ea4e1ecf..09beb82bfb 100644 --- a/puppet/services/memcached.yaml +++ b/puppet/services/memcached.yaml @@ -39,6 +39,21 @@ parameters: MonitoringSubscriptionMemcached: default: 'overcloud-memcached' type: string + Debug: + default: false + description: Set to True to enable debugging on all services. + type: boolean + MemcachedDebug: + default: '' + description: Set to True to enable debugging Memcached service. + type: string + +conditions: + service_debug: + or: + - equals: [{get_param: MemcachedDebug}, 'true'] + - equals: [{get_param: MemcachedDebug}, 'True'] + - equals: [{get_param: Debug}, true] outputs: role_data: @@ -54,7 +69,14 @@ outputs: # internal_api_subnet - > IP/CIDR memcached::listen_ip: {get_param: [ServiceNetMap, MemcachedNetwork]} memcached::max_memory: {get_param: MemcachedMaxMemory} - memcached::verbosity: 'v' + memcached::verbosity: + list_join: + - '' + - - 'v' + - if: + - service_debug + - 'v' + - '' tripleo.memcached.firewall_rules: '121 memcached': dport: 11211 diff --git a/releasenotes/notes/memcached-verbose-logs-84ca938d76c16429.yaml b/releasenotes/notes/memcached-verbose-logs-84ca938d76c16429.yaml new file mode 100644 index 0000000000..9392e6c429 --- /dev/null +++ b/releasenotes/notes/memcached-verbose-logs-84ca938d76c16429.yaml @@ -0,0 +1,6 @@ +--- +features: + - | + The memcached service now reacts to the Debug flag, which will make its + logs verbose. Also, the MemcachedDebug flag was added, which will just add + this for the individual service.