I get the following error when I try to get the Hanode stat using the FindAllStats function.
panic: interface conversion: interface {} is map[string]interface {}, not []interface {}
The reproduced code is as follows.
package main
import (
"fmt"
"os"
"github.com/citrix/adc-nitro-go/service"
)
func main() {
client, err := service.NewNitroClientFromEnv()
if err != nil {
fmt.Println(err)
os.Exit(1)
}
haStats, err := client.FindAllStats(service.Hanode.Type())
if err != nil {
fmt.Println(err)
os.Exit(1)
}
fmt.Println(haStats)
}
I get the following error when I try to get the Hanode stat using the FindAllStats function.
The reproduced code is as follows.