Closed PGHPE closed 5 years ago
Using GetEnclosureByName, the return value for OaBayCount is 0
Using the OneView 4.10 Simulator,
I have the following code:
package main
import ( "fmt"
"github.com/HewlettPackard/oneview-golang/ov"
)
func main() {
// Connect var ( clientOV *ov.OVClient ) ovc := clientOV.NewOVClient("Administrator", "password", "", "https://192.168.1.15", false, 600, "*") // Get Enclosure List enclist, _ := ovc.GetEnclosures("", "", "", "", "") // Get Detail of each Enclosure for i := 0; i < len(enclist.Members); i++ { enc, _ := ovc.GetEnclosureByName(enclist.Members[i].Name) fmt.Println(enc.SerialNumber) fmt.Println("OA Count: ", enc.OaBayCount) fmt.Println("IC Count: ", enc.InterconnectBayCount) fmt.Println("Bay Count: ", enc.DeviceBayCount) fmt.Println("OA Lenght:", len(enc.OA)) fmt.Println("VC Lenght:", len(enc.InterconnectBays)) fmt.Println("Bay Lenght:", len(enc.DeviceBays)) fmt.Println() }
}
The output is this code is:
SGH100X6J1 OA Count: 0 IC Count: 8 Bay Count: 16 OA Lenght: 0 VC Lenght: 8 Bay Lenght: 16
SGH102X6J1 OA Count: 0 IC Count: 8 Bay Count: 16 OA Lenght: 0 VC Lenght: 8 Bay Lenght: 16
enc.OaBayCount = 2 len(enc.OA) = 2
OaBayCount = 0 Also, OAMAP is reporting 0
Issue Fixed in PR https://github.com/HewlettPackard/oneview-golang/pull/156
Scenario/Intent
Using GetEnclosureByName, the return value for OaBayCount is 0
Environment Details
Steps to Reproduce
Using the OneView 4.10 Simulator,
I have the following code:
package main
import ( "fmt"
)
func main() {
}
The output is this code is:
SGH100X6J1 OA Count: 0 IC Count: 8 Bay Count: 16 OA Lenght: 0 VC Lenght: 8 Bay Lenght: 16
SGH102X6J1 OA Count: 0 IC Count: 8 Bay Count: 16 OA Lenght: 0 VC Lenght: 8 Bay Lenght: 16
Expected Result
enc.OaBayCount = 2 len(enc.OA) = 2
Actual Result
OaBayCount = 0 Also, OAMAP is reporting 0