Use specific log name for independent daemons

Use specific log name for container-reconciler and object-expirer so
that operators can easily distinguish their logs from the logs
generated by the other services.

Change-Id: I918c90789ccd4fef5478ea51440ee22345986342
This commit is contained in:
Takashi Kajinami
2024-10-27 01:56:24 +09:00
parent 8afd4fa6d3
commit fbe591166c
4 changed files with 7 additions and 7 deletions

View File

@@ -89,11 +89,11 @@
#
# [*log_name*]
# (optional) Log name.
# Defaults to $facts['os_service_default'].
# Defaults to 'container-reconciler'.
#
# [*log_level*]
# (optional) Log level.
# Defaults to $facts['os_service_default'].
# Defaults to 'INFO'.
#
# [*log_facility*]
# (optional) Log level
@@ -129,7 +129,7 @@ class swift::containerreconciler(
$cache_tls_cafile = $facts['os_service_default'],
$cache_tls_certfile = $facts['os_service_default'],
$cache_tls_keyfile = $facts['os_service_default'],
$log_name = $facts['os_service_default'],
$log_name = 'container-reconciler',
$log_level = 'INFO',
$log_facility = 'LOG_LOCAL2',
$log_address = '/dev/log',

View File

@@ -95,7 +95,7 @@
#
# [*log_name*]
# (optional) Log name.
# Defaults to $facts['os_service_default'].
# Defaults to 'object-expirer'.
#
# [*log_level*]
# (optional) Log level.
@@ -137,7 +137,7 @@ class swift::objectexpirer(
$cache_tls_cafile = $facts['os_service_default'],
$cache_tls_certfile = $facts['os_service_default'],
$cache_tls_keyfile = $facts['os_service_default'],
$log_name = $facts['os_service_default'],
$log_name = 'object-expirer',
$log_level = 'INFO',
$log_facility = 'LOG_LOCAL2',
$log_address = '/dev/log',

View File

@@ -35,7 +35,7 @@ describe 'swift::containerreconciler' do
is_expected.to contain_swift_container_reconciler_config(
'container-reconciler/request_tries').with_value('<SERVICE DEFAULT>')
is_expected.to contain_swift_container_reconciler_config(
'container-reconciler/log_name').with_value('<SERVICE DEFAULT>')
'container-reconciler/log_name').with_value('container-reconciler')
is_expected.to contain_swift_container_reconciler_config(
'container-reconciler/log_level').with_value('INFO')
is_expected.to contain_swift_container_reconciler_config(

View File

@@ -39,7 +39,7 @@ describe 'swift::objectexpirer' do
is_expected.to contain_swift_object_expirer_config(
'object-expirer/report_interval').with_value('<SERVICE DEFAULT>')
is_expected.to contain_swift_object_expirer_config(
'object-expirer/log_name').with_value('<SERVICE DEFAULT>')
'object-expirer/log_name').with_value('object-expirer')
is_expected.to contain_swift_object_expirer_config(
'object-expirer/log_level').with_value('INFO')
is_expected.to contain_swift_object_expirer_config(