Newer
Older
"code.fbi.h-da.de/cocsn/gosdn/nucleus/errors"
"code.fbi.h-da.de/cocsn/gosdn/forks/goarista/gnmi"
"code.fbi.h-da.de/cocsn/gosdn/nucleus"
gpb "github.com/openconfig/gnmi/proto/gnmi"
log "github.com/sirupsen/logrus"
)
// Get sends a gNMI Get request to the specified target and prints the response to stdout
func Get(a, u, p string, args ...string) (*gpb.GetResponse, error) {
sbi := &nucleus.OpenConfig{}
opts := &nucleus.GnmiTransportOptions{
Config: gnmi.Config{
Encoding: gpb.Encoding_JSON_IETF,
},
SetNode: sbi.SetNode(),
}
log.Debug(resp)
r, ok := resp.(*gpb.GetResponse)
if !ok {
return nil, &errors.ErrInvalidTypeAssertion{}