aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBryn M. Reeves <bmr@redhat.com>2014-07-07 15:27:11 +0100
committerBryn M. Reeves <bmr@redhat.com>2014-07-07 15:27:11 +0100
commitc6cbca435ed1c14a739574e67380c764ade2bdef (patch)
tree8f105ccd988648b8abfbca5248a21acdb3d04fe6
parent9ac99e085ae8b1bfd02937282897c06cd73d934f (diff)
downloadsos-c6cbca435ed1c14a739574e67380c764ade2bdef.tar.gz
[plugin] kill Plugin.option_enabled()
Has been deprecated for years. Kill it and replace the remaining uses with Plugin.get_option(). Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
-rw-r--r--sos/plugins/__init__.py4
-rw-r--r--sos/plugins/nscd.py2
-rw-r--r--sos/plugins/openstack_cinder.py4
-rw-r--r--sos/plugins/openstack_horizon.py4
-rw-r--r--sos/plugins/openstack_keystone.py2
-rw-r--r--sos/plugins/openstack_nova.py4
6 files changed, 8 insertions, 12 deletions
diff --git a/sos/plugins/__init__.py b/sos/plugins/__init__.py
index 2730a990..97c28140 100644
--- a/sos/plugins/__init__.py
+++ b/sos/plugins/__init__.py
@@ -367,10 +367,6 @@ class Plugin(object):
else:
return False
- def option_enabled(self, optionname):
- '''Deprecated, use get_option() instead'''
- return self.get_option(optionname)
-
def get_option(self, optionname, default=0):
"""Returns the first value that matches 'optionname' in parameters
passed in via the command line or set via set_option or via the
diff --git a/sos/plugins/nscd.py b/sos/plugins/nscd.py
index 339f52ea..c880e63b 100644
--- a/sos/plugins/nscd.py
+++ b/sos/plugins/nscd.py
@@ -36,6 +36,6 @@ class Nscd(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
for o in opt:
f = o.split()
self.add_copy_spec_limit(f[1],
- sizelimit = self.option_enabled("nscdlogsize"))
+ sizelimit = self.get_option("nscdlogsize"))
# vim: et ts=4 sw=4
diff --git a/sos/plugins/openstack_cinder.py b/sos/plugins/openstack_cinder.py
index 10266de2..5c480708 100644
--- a/sos/plugins/openstack_cinder.py
+++ b/sos/plugins/openstack_cinder.py
@@ -31,14 +31,14 @@ class OpenStackCinder(Plugin):
("db", "gathers openstack cinder db version", "slow", False)]
def setup(self):
- if self.option_enabled("db"):
+ if self.get_option("db"):
self.add_cmd_output(
"cinder-manage db version",
suggest_filename="cinder_db_version")
self.add_copy_specs(["/etc/cinder/"])
- if self.option_enabled("log"):
+ if self.get_option("log"):
self.add_copy_specs(["/var/log/cinder/"])
diff --git a/sos/plugins/openstack_horizon.py b/sos/plugins/openstack_horizon.py
index 0c7ccc00..58bdc490 100644
--- a/sos/plugins/openstack_horizon.py
+++ b/sos/plugins/openstack_horizon.py
@@ -30,7 +30,7 @@ class OpenStackHorizon(Plugin):
def setup(self):
self.add_copy_spec("/etc/openstack-dashboard/")
- if self.option_enabled("log"):
+ if self.get_option("log"):
self.add_copy_spec("/var/log/horizon/")
@@ -76,7 +76,7 @@ class RedHatOpenStackHorizon(OpenStackHorizon, RedHatPlugin):
def setup(self):
super(RedHatOpenStackHorizon, self).setup()
self.add_copy_spec("/etc/httpd/conf.d/openstack-dashboard.conf")
- if self.option_enabled("log"):
+ if self.get_option("log"):
self.add_copy_spec("/var/log/httpd/")
# vim: et ts=4 sw=4
diff --git a/sos/plugins/openstack_keystone.py b/sos/plugins/openstack_keystone.py
index b3683e45..cc8ce265 100644
--- a/sos/plugins/openstack_keystone.py
+++ b/sos/plugins/openstack_keystone.py
@@ -35,7 +35,7 @@ class OpenStackKeystone(Plugin):
"/etc/keystone/policy.json"
])
- if self.option_enabled("log"):
+ if self.get_option("log"):
self.add_copy_spec("/var/log/keystone/")
def postproc(self):
diff --git a/sos/plugins/openstack_nova.py b/sos/plugins/openstack_nova.py
index 9f0fd8b2..104ad33b 100644
--- a/sos/plugins/openstack_nova.py
+++ b/sos/plugins/openstack_nova.py
@@ -28,7 +28,7 @@ class OpenStackNova(Plugin):
("cmds", "gathers openstack nova commands", "slow", False)]
def setup(self):
- if self.option_enabled("cmds"):
+ if self.get_option("cmds"):
self.add_cmd_output(
"nova-manage config list",
suggest_filename="nova_config_list")
@@ -54,7 +54,7 @@ class OpenStackNova(Plugin):
"nova-manage vm list",
suggest_filename="nova_vm_list")
- if self.option_enabled("log"):
+ if self.get_option("log"):
self.add_copy_spec("/var/log/nova/")
self.add_copy_spec("/etc/nova/")