[master 2/5] Remove services infrastructure from devices and formats.
mulkieran
installerbot-noreply at redhat.com
Wed Mar 4 01:53:39 UTC 2015
From: mulhern <amulhern at redhat.com>
It was added for bz #615040 so that multipathd could be started
in the configuration step (after installation).
multipathd.service is "WantedBy" sysinit.target, so it is expected that it
does not need to be explicitly started by anaconda. services infrastructure
is not used anywhere else.
Signed-off-by: mulhern <amulhern at redhat.com>
---
blivet/devices/device.py | 15 ---------------
blivet/devices/disk.py | 1 -
blivet/devices/storage.py | 17 -----------------
blivet/formats/__init__.py | 6 ------
4 files changed, 39 deletions(-)
diff --git a/blivet/devices/device.py b/blivet/devices/device.py
index a23a74c..d478fed 100644
--- a/blivet/devices/device.py
+++ b/blivet/devices/device.py
@@ -66,7 +66,6 @@ class Device(util.ObjectID):
_type = "device"
_packages = []
- _services = []
def __init__(self, name, parents=None):
"""
@@ -290,20 +289,6 @@ def packages(self):
return packages
@property
- def services(self):
- """ List of services required to manage devices of this type.
-
- This list includes the services required by its parent devices."
- """
- services = self._services
- for parent in self.parents:
- for service in parent.services:
- if service not in services:
- services.append(service)
-
- return services
-
- @property
def mediaPresent(self):
""" True if this device contains usable media. """
return True
diff --git a/blivet/devices/disk.py b/blivet/devices/disk.py
index ec0ea7e..0d129d2 100644
--- a/blivet/devices/disk.py
+++ b/blivet/devices/disk.py
@@ -249,7 +249,6 @@ class MultipathDevice(DMDevice):
""" A multipath device """
_type = "dm-multipath"
_packages = ["device-mapper-multipath"]
- _services = ["multipathd"]
_partitionable = True
_isDisk = True
diff --git a/blivet/devices/storage.py b/blivet/devices/storage.py
index 311df3e..61b5733 100644
--- a/blivet/devices/storage.py
+++ b/blivet/devices/storage.py
@@ -164,23 +164,6 @@ def packages(self):
return packages
@property
- def services(self):
- """ List of services required to manage devices of this type.
-
- This list includes the services required by this device's
- format type as well those required by all of its parent
- devices.
- """
- services = super(StorageDevice, self).services
- services.extend(self.format.services)
- for parent in self.parents:
- for service in parent.format.services:
- if service not in services:
- services.append(service)
-
- return services
-
- @property
def disks(self):
""" A list of all disks this device depends on, including itself. """
_disks = []
diff --git a/blivet/formats/__init__.py b/blivet/formats/__init__.py
index 6d5da47..5147601 100644
--- a/blivet/formats/__init__.py
+++ b/blivet/formats/__init__.py
@@ -153,7 +153,6 @@ class DeviceFormat(ObjectID):
_supported = False # is supported
_linuxNative = False # for clearpart
_packages = [] # required packages
- _services = [] # required services
_resizable = False # can be resized
_maxSize = Size(0) # maximum size
_minSize = Size(0) # minimum size
@@ -470,11 +469,6 @@ def packages(self):
return self._packages
@property
- def services(self):
- """ Services required to manage formats of this type. """
- return self._services
-
- @property
def resizable(self):
""" Can formats of this type be resized? """
return self._resizable and self.exists
--
To view this commit on github, visit https://github.com/rhinstaller/blivet/commit/6bf1766497fa32758a5fbaf587d5fb0759e18b9d
More information about the anaconda-patches
mailing list