Merge "Use 'False' as default value for "compression" common capability"
This commit is contained in:
commit
cd4f0ef569
|
@ -126,6 +126,7 @@ class HostState(object):
|
||||||
self.snapshot_support = True
|
self.snapshot_support = True
|
||||||
self.consistency_group_support = False
|
self.consistency_group_support = False
|
||||||
self.dedupe = False
|
self.dedupe = False
|
||||||
|
self.compression = False
|
||||||
|
|
||||||
# PoolState for all pools
|
# PoolState for all pools
|
||||||
self.pools = {}
|
self.pools = {}
|
||||||
|
@ -288,6 +289,9 @@ class HostState(object):
|
||||||
if 'dedupe' not in pool_cap:
|
if 'dedupe' not in pool_cap:
|
||||||
pool_cap['dedupe'] = self.dedupe
|
pool_cap['dedupe'] = self.dedupe
|
||||||
|
|
||||||
|
if 'compression' not in pool_cap:
|
||||||
|
pool_cap['compression'] = self.compression
|
||||||
|
|
||||||
def update_backend(self, capability):
|
def update_backend(self, capability):
|
||||||
self.share_backend_name = capability.get('share_backend_name')
|
self.share_backend_name = capability.get('share_backend_name')
|
||||||
self.vendor_name = capability.get('vendor_name')
|
self.vendor_name = capability.get('vendor_name')
|
||||||
|
@ -359,6 +363,8 @@ class PoolState(HostState):
|
||||||
'thin_provisioning', False)
|
'thin_provisioning', False)
|
||||||
self.dedupe = capability.get(
|
self.dedupe = capability.get(
|
||||||
'dedupe', False)
|
'dedupe', False)
|
||||||
|
self.compression = capability.get(
|
||||||
|
'compression', False)
|
||||||
|
|
||||||
def update_pools(self, capability):
|
def update_pools(self, capability):
|
||||||
# Do nothing, since we don't have pools within pool, yet
|
# Do nothing, since we don't have pools within pool, yet
|
||||||
|
|
|
@ -197,6 +197,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'snapshot_support': False,
|
'snapshot_support': False,
|
||||||
'consistency_group_support': False,
|
'consistency_group_support': False,
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
}, {
|
}, {
|
||||||
'name': 'host2@back1#BBB',
|
'name': 'host2@back1#BBB',
|
||||||
|
@ -219,6 +220,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'snapshot_support': True,
|
'snapshot_support': True,
|
||||||
'consistency_group_support': False,
|
'consistency_group_support': False,
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
}, {
|
}, {
|
||||||
'name': 'host2@back2#CCC',
|
'name': 'host2@back2#CCC',
|
||||||
|
@ -241,6 +243,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'snapshot_support': True,
|
'snapshot_support': True,
|
||||||
'consistency_group_support': False,
|
'consistency_group_support': False,
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
@ -285,6 +288,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'snapshot_support': True,
|
'snapshot_support': True,
|
||||||
'consistency_group_support': False,
|
'consistency_group_support': False,
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
}, {
|
}, {
|
||||||
'name': 'host2@BBB#pool2',
|
'name': 'host2@BBB#pool2',
|
||||||
|
@ -308,6 +312,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'snapshot_support': True,
|
'snapshot_support': True,
|
||||||
'consistency_group_support': False,
|
'consistency_group_support': False,
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
}, {
|
}, {
|
||||||
'name': 'host3@CCC#pool3',
|
'name': 'host3@CCC#pool3',
|
||||||
|
@ -331,6 +336,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'snapshot_support': True,
|
'snapshot_support': True,
|
||||||
'consistency_group_support': 'pool',
|
'consistency_group_support': 'pool',
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
}, {
|
}, {
|
||||||
'name': 'host4@DDD#pool4a',
|
'name': 'host4@DDD#pool4a',
|
||||||
|
@ -354,6 +360,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'snapshot_support': True,
|
'snapshot_support': True,
|
||||||
'consistency_group_support': 'host',
|
'consistency_group_support': 'host',
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
}, {
|
}, {
|
||||||
'name': 'host4@DDD#pool4b',
|
'name': 'host4@DDD#pool4b',
|
||||||
|
@ -377,6 +384,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'snapshot_support': True,
|
'snapshot_support': True,
|
||||||
'consistency_group_support': 'host',
|
'consistency_group_support': 'host',
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
@ -433,6 +441,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'thin_provisioning': False,
|
'thin_provisioning': False,
|
||||||
'consistency_group_support': False,
|
'consistency_group_support': False,
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
}, {
|
}, {
|
||||||
'name': 'host2@back1#BBB',
|
'name': 'host2@back1#BBB',
|
||||||
|
@ -455,6 +464,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'thin_provisioning': True,
|
'thin_provisioning': True,
|
||||||
'consistency_group_support': False,
|
'consistency_group_support': False,
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
@ -503,6 +513,7 @@ class HostManagerTestCase(test.TestCase):
|
||||||
'storage_protocol': None,
|
'storage_protocol': None,
|
||||||
'consistency_group_support': False,
|
'consistency_group_support': False,
|
||||||
'dedupe': False,
|
'dedupe': False,
|
||||||
|
'compression': False,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
|
Loading…
Reference in New Issue