Skip to content

Commit

Permalink
conf: remove unused reconnection_retries
Browse files Browse the repository at this point in the history
This option is no longer used since 9f8551a

Resolves: #7502
  • Loading branch information
pbrezina committed Oct 3, 2024
1 parent 4295e00 commit 02f5a6b
Show file tree
Hide file tree
Showing 13 changed files with 0 additions and 106 deletions.
1 change: 0 additions & 1 deletion src/confdb/confdb.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@
#define CONFDB_SERVICE_DEBUG_TIMESTAMPS "debug_timestamps"
#define CONFDB_SERVICE_DEBUG_MICROSECONDS "debug_microseconds"
#define CONFDB_SERVICE_DEBUG_BACKTRACE_ENABLED "debug_backtrace_enabled"
#define CONFDB_SERVICE_RECON_RETRIES "reconnection_retries"
#define CONFDB_SERVICE_FD_LIMIT "fd_limit"
#define CONFDB_SERVICE_ALLOWED_UIDS "allowed_uids"

Expand Down
1 change: 0 additions & 1 deletion src/config/SSSDConfig/sssdoptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ def __init__(self):
'debug_backtrace_enabled': _('Enable/disable debug backtrace'),
'timeout': _('Watchdog timeout before restarting service'),
'command': _('Command to start service'),
'reconnection_retries': _('Number of times to attempt connection to Data Providers'),
'fd_limit': _('The number of file descriptors that may be opened by this responder'),
'client_idle_timeout': _('Idle time before automatic disconnection of a client'),
'responder_idle_timeout': _('Idle time before automatic shutdown of the responder'),
Expand Down
25 changes: 0 additions & 25 deletions src/config/SSSDConfigTest.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,6 @@ def testServices(self):

self.assertTrue('domains' in service_opts)

self.assertTrue('reconnection_retries' in service_opts)

del sssdconfig
sssdconfig = SSSDConfig.SSSDConfig(srcdir + "/etc/sssd.api.conf",
srcdir + "/etc/sssd.api.d")
Expand All @@ -93,9 +91,6 @@ def testServices(self):
self.assertTrue('command' in new_options)
self.assertEqual(new_options['command'][0], str)

self.assertTrue('reconnection_retries' in new_options)
self.assertEqual(new_options['reconnection_retries'][0], int)

self.assertTrue('services' in new_options)
self.assertEqual(new_options['debug_level'][0], int)

Expand Down Expand Up @@ -338,7 +333,6 @@ def testListOptions(self):
'debug_microseconds',
'debug_backtrace_enabled',
'command',
'reconnection_retries',
'fd_limit',
'client_idle_timeout',
'responder_idle_timeout',
Expand Down Expand Up @@ -371,22 +365,6 @@ def testListOptions(self):
'Option [%s] unexpectedly found' %
option)

self.assertTrue(type(options['reconnection_retries']) == tuple,
"Option values should be a tuple")

self.assertTrue(options['reconnection_retries'][0] == int,
"reconnection_retries should require an int. "
"list_options is requiring a %s" %
options['reconnection_retries'][0])

self.assertTrue(options['reconnection_retries'][1] is None,
"reconnection_retries should not require a subtype. "
"list_options is requiring a %s" %
options['reconnection_retries'][1])

self.assertTrue(options['reconnection_retries'][3] is None,
"reconnection_retries should have no default")

self.assertTrue(type(options['services']) == tuple,
"Option values should be a tuple")

Expand Down Expand Up @@ -1235,7 +1213,6 @@ def testImportConfig(self):
# Verify that all options were imported for a section
control_list = [
'services',
'reconnection_retries',
'domains',
'debug_timestamps']

Expand Down Expand Up @@ -1292,7 +1269,6 @@ def testImportConfigNoVersion(self):
service_list = sssd_service.get_option('services')
self.assertTrue('nss' in service_list)
self.assertTrue('pam' in service_list)
self.assertTrue('reconnection_retries' in service_opts)

# Validate domain list
domains = sssdconfig.list_domains()
Expand Down Expand Up @@ -2070,7 +2046,6 @@ def testEnabledOption(self):
# Verify that all options were imported for [sssd] section
control_list = [
'services',
'reconnection_retries',
'domains',
'debug_timestamps']

Expand Down
10 changes: 0 additions & 10 deletions src/config/cfg_rules.ini
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand Down Expand Up @@ -68,7 +67,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand Down Expand Up @@ -111,7 +109,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand Down Expand Up @@ -158,7 +155,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand All @@ -181,7 +177,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand All @@ -202,7 +197,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand All @@ -227,7 +221,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand All @@ -250,7 +243,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand All @@ -273,7 +265,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand Down Expand Up @@ -360,7 +351,6 @@ option = debug_timestamps
option = debug_microseconds
option = debug_backtrace_enabled
option = command
option = reconnection_retries
option = fd_limit
option = client_idle_timeout
option = description
Expand Down
1 change: 0 additions & 1 deletion src/config/etc/sssd.api.conf
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ debug_timestamps = bool, None, false
debug_microseconds = bool, None, false
debug_backtrace_enabled = bool, None, false
command = str, None, false
reconnection_retries = int, None, false
fd_limit = int, None, false
client_idle_timeout = int, None, false
responder_idle_timeout = int, None, false
Expand Down
1 change: 0 additions & 1 deletion src/config/testconfigs/sssd-enabled-option.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ debug_level = 0

[sssd]
services = nss, pam
reconnection_retries = 3
domains = enabled_1, enabled_3, disabled_3
debug_timestamps = False

Expand Down
1 change: 0 additions & 1 deletion src/config/testconfigs/sssd-invalid-badbool.conf
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ nss_enum_cache_timeout = 120

[sssd]
services = nss, pam
reconnection_retries = 3
domains = PROXY, IPA

[domain/PROXY]
Expand Down
1 change: 0 additions & 1 deletion src/config/testconfigs/sssd-noversion.conf
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ nss_enum_cache_timeout = 120

[sssd]
services = nss, pam
reconnection_retries = 3
domains = PROXY, IPA

[domain/PROXY]
Expand Down
1 change: 0 additions & 1 deletion src/config/testconfigs/sssd-valid.conf
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ nss_enum_cache_timeout = 120

[sssd]
services = nss, pam
reconnection_retries = 3
domains = IPA
debug_timestamps = False

Expand Down
26 changes: 0 additions & 26 deletions src/man/sssd.conf.5.xml
Original file line number Diff line number Diff line change
Expand Up @@ -247,19 +247,6 @@
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>reconnection_retries (integer)</term>
<listitem>
<para>
Number of times services should attempt to
reconnect in the event of a Data Provider
crash or restart before they give up
</para>
<para>
Default: 3
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>domains</term>
<listitem>
Expand Down Expand Up @@ -777,19 +764,6 @@
These options can be used to configure any service.
</para>
<variablelist>
<varlistentry>
<term>reconnection_retries (integer)</term>
<listitem>
<para>
Number of times services should attempt to
reconnect in the event of a Data Provider
crash or restart before they give up
</para>
<para>
Default: 3
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>fd_limit</term>
<listitem>
Expand Down
3 changes: 0 additions & 3 deletions src/tests/multihost/alltests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -1506,11 +1506,8 @@ def ns_account_lock(session_multihost, request):
'ldap_account_expire_policy': '389DS',
'ldap_ns_account_lock': 'nsAccountlock'}
client.sssd_conf(f'domain/{domain_name}', domain_params)
domain_params = {'reconnection_retries': '3'}
client.sssd_conf('pam', domain_params)
domain_params = {'filter_groups': 'root',
'filter_users': 'root',
'reconnection_retries': '3',
'debug_level': '9'}
client.sssd_conf('nss', domain_params)
session_multihost.client[0].service_sssd('restart')
Expand Down
33 changes: 0 additions & 33 deletions src/tests/multihost/alltests/test_misc.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,39 +81,6 @@ def test_0001_ldapcachepurgetimeout(self,
multihost.client[0].service_sssd('start')
assert status == 'PASS'

@pytest.mark.tier1
def test_0002_offbyonereconn(self,
multihost, backupsssdconf):
"""
:title: off by one in reconnection retries option intepretation
:id: 85c5357d-0cc4-4a32-b36a-00ed530865ad
:customerscenario: True
:bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1801401
"""
tools = sssdTools(multihost.client[0])
multihost.client[0].service_sssd('stop')
tools.remove_sss_cache('/var/lib/sss/db')
params = {'debug_level': '9',
'reconnection_retries': '1'}
tools.sssd_conf('nss', params)
multihost.client[0].service_sssd('start')
kill_sssd_be = 'pkill sssd_be'
try:
multihost.client[0].run_command(kill_sssd_be, raiseonerr=False)
except subprocess.CalledProcessError:
pytest.fail("Unable to kill the sssd_be process")
time.sleep(3)
log_file = '/var/log/sssd/sssd_nss.log'
log_str = multihost.client[0].get_file_contents(log_file)
log1 = re.compile(r'Performing\sauto-reconnect')
result = log1.search(log_str.decode())
getent = 'getent passwd foo1@%s' % ds_instance_name
cmd = multihost.client[0].run_command(getent, raiseonerr=False)
multihost.client[0].service_sssd('stop')
tools.sssd_conf('nss', params, action='delete')
multihost.client[0].service_sssd('start')
assert result is not None or cmd.returncode == 0

@pytest.mark.tier1
def test_0003_sssd_crashes_after_update(self, multihost,
backupsssdconf):
Expand Down
2 changes: 0 additions & 2 deletions src/tests/multihost/alltests/test_multidomain.py
Original file line number Diff line number Diff line change
Expand Up @@ -511,8 +511,6 @@ def test_0023_ldapldap(multihost, multidomain_sssd):
domain_section = 'domain/ldap%d' % (idx + 1)
client_tools.sssd_conf(domain_section, params)
domains = ['ldap1, ldap2', 'ldap2, ldap1']
sssd_params = {'reconnection_retries': '3'}
client_tools.sssd_conf('sssd', sssd_params)
for domain in domains:
sssd_params = {'domains': domain}
client_tools.sssd_conf('sssd', sssd_params)
Expand Down

0 comments on commit 02f5a6b

Please sign in to comment.