summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTony Asleson <tasleson@redhat.com>2016-06-06 15:08:20 -0500
committerTony Asleson <tasleson@redhat.com>2016-06-28 12:09:28 -0500
commit4b337b20d47953e130edc8a456e9431eba58a778 (patch)
tree837d0da918e94ed89f19ff23d79b27304d3cbb61
parente514284c65a7cffa24549a34612392731f6e06af (diff)
downloadlvm2-4b337b20d47953e130edc8a456e9431eba58a778.tar.gz
lvmdbusd: Remove sorting in db layer
When using the JSON this does not yield a totally sorted list as we don't have a complete set of LVs, so remove this sort.
-rwxr-xr-xdaemons/lvmdbusd/lvmdb.py8
1 files changed, 1 insertions, 7 deletions
diff --git a/daemons/lvmdbusd/lvmdb.py b/daemons/lvmdbusd/lvmdb.py
index 5ac90e37d..f070bb618 100755
--- a/daemons/lvmdbusd/lvmdb.py
+++ b/daemons/lvmdbusd/lvmdb.py
@@ -245,16 +245,10 @@ class DataStore(object):
# Each item item in the report is a collection of information pertaining
# to the vg
for r in _all['report']:
- tmp_lv = []
# Get the lv data for this VG.
if 'lv' in r:
- tmp_lv.extend(r['lv'])
-
- # Sort them
- sorted_tmp_lv = sorted(tmp_lv, key=lambda vk: vk['lv_name'])
-
# Add them to result set
- for i in sorted_tmp_lv:
+ for i in r['lv']:
full_name = "%s/%s" % (i['vg_name'], i['lv_name'])
c_lv_full_lookup[full_name] = i['lv_uuid']
c_lvs[i['lv_uuid']] = i