RAID interface to support JBOD volumes
Adding 'JBOD' to the list of accepted RAID levels. Closes-Bug: #1572511 Change-Id: I596b26d10331aed9696c8fbd75b9e1d683af8587
This commit is contained in:
parent
67652e530e
commit
0f8cfa8012
@ -9,8 +9,8 @@
|
||||
"properties": {
|
||||
"raid_level": {
|
||||
"type": "string",
|
||||
"enum": [ "0", "1", "2", "5", "6", "1+0", "5+0", "6+0" ],
|
||||
"description": "RAID level for the logical disk. Valid values are '0', '1', '2', '5', '6', '1+0', '5+0' and '6+0'. Required."
|
||||
"enum": [ "JBOD", "0", "1", "2", "5", "6", "1+0", "5+0", "6+0" ],
|
||||
"description": "RAID level for the logical disk. Valid values are 'JBOD', 0', '1', '2', '5', '6', '1+0', '5+0' and '6+0'. Required."
|
||||
},
|
||||
"size_gb": {
|
||||
"anyOf": [{
|
||||
|
@ -141,6 +141,11 @@ class ValidateRaidConfigurationTestCase(base.TestCase):
|
||||
raid_config,
|
||||
raid_config_schema=self.schema)
|
||||
|
||||
def test_validate_configuration_with_jbod_volume(self):
|
||||
raid_config = json.loads(raid_constants.RAID_CONFIG_JBOD_VOLUME)
|
||||
raid.validate_configuration(raid_config,
|
||||
raid_config_schema=self.schema)
|
||||
|
||||
def test_validate_configuration_custom_schema(self):
|
||||
raid_config = json.loads(raid_constants.CUSTOM_SCHEMA_RAID_CONFIG)
|
||||
schema = json.loads(raid_constants.CUSTOM_RAID_SCHEMA)
|
||||
|
@ -196,6 +196,17 @@ RAID_CONFIG_ADDITIONAL_PROP = '''
|
||||
}
|
||||
'''
|
||||
|
||||
RAID_CONFIG_JBOD_VOLUME = '''
|
||||
{
|
||||
"logical_disks": [
|
||||
{
|
||||
"raid_level": "JBOD",
|
||||
"size_gb": 100
|
||||
}
|
||||
]
|
||||
}
|
||||
'''
|
||||
|
||||
CUSTOM_SCHEMA_RAID_CONFIG = '''
|
||||
{
|
||||
"logical_disks": [
|
||||
|
@ -0,0 +1,3 @@
|
||||
---
|
||||
features:
|
||||
- Added support for JBOD volumes in RAID configuration.
|
Loading…
Reference in New Issue
Block a user