-
Notifications
You must be signed in to change notification settings - Fork 7
Description
I'm encountering more and more raid cards that are only compatible with storcli2/percli2, which is problematic with the current library. For the most part the commands are roughly the same, but the output is different. What do we think is the best way to handle different output like this? It would be relatively simple if the keys were just different in name, but some are nested under varying levels of keys to get the same answer; ie
storcli64 output for getting virtual drive facts
"Response Data" : {
"VD0 Properties" : {
"Strip Size" : "256 KB",
storcli2 output for getting virtual drive facts
"Response Data" : {
"Virtual Drives" : [
{
"VD Info" : {
"DG/VD" : "0/1",
"TYPE" : "RAID6",
"State" : "Optl",
"Access" : "RW",
"CurrentCache" : "NR,AWB",
"DefaultCache" : "NR,AWB",
"Size" : "392.896 TiB",
"Name" : ""
},
"PDs" : [
{
"EID:Slt" : "355:6",
...
"Alt-EID" : "-"
}
],
"VD Properties" : {
"Strip Size" : "256 KiB",
"Block Size" : 4096,
"Number of Blocks" : 1054674616
Is it best to keep it in the same library? Create a new library? Probably goes along the lines the of the factory pattern conversation and pyarcconf.