gnmi_sonic

package
v0.0.0-...-bfb01b6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 23, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package gnmi_sonic is a generated protocol buffer package.

It is generated from these files:

dial_out.proto
sonic.proto
sonic_internal.proto

It has these top-level messages:

PublishResponse
Value

Index

Constants

This section is empty.

Variables

View Source
var State_name = map[int32]string{
	0: "STOPPED",
	1: "INIT",
	2: "RUNNING",
}
View Source
var State_value = map[string]int32{
	"STOPPED": 0,
	"INIT":    1,
	"RUNNING": 2,
}
View Source
var Target_name = map[int32]string{
	0: "APPL_DB",
	1: "ASIC_DB",
	2: "COUNTERS_DB",
	3: "LOGLEVEL_DB",
	4: "CONFIG_DB",
	5: "PFC_WD_DB",

	6:   "STATE_DB",
	100: "OTHERS",
}
View Source
var Target_value = map[string]int32{
	"APPL_DB":         0,
	"ASIC_DB":         1,
	"COUNTERS_DB":     2,
	"LOGLEVEL_DB":     3,
	"CONFIG_DB":       4,
	"PFC_WD_DB":       5,
	"FLEX_COUNTER_DB": 5,
	"STATE_DB":        6,
	"OTHERS":          100,
}

Functions

func RegisterGNMIDialOutServer

func RegisterGNMIDialOutServer(s *grpc.Server, srv GNMIDialOutServer)

Types

type GNMIDialOutClient

type GNMIDialOutClient interface {
	// Publish allows the target to send telemetry updates (in the form of
	// SubscribeResponse messaages, which have the same semantics as in the
	// gNMI Subscribe RPC, to a client. The client may optionally return the
	// PublishResponse message in response to the dial-out connection from the
	// target as acknowledgement to the SubscribeResponse message
	//
	// The configuration of subscriptions associated with the publish RPC may
	// be through the OpenConfig telemetry configuration and operational state
	// model:
	// https://github.com/openconfig/public/blob/master/release/models/telemetry/openconfig-telemetry.yang
	Publish(ctx context.Context, opts ...grpc.CallOption) (GNMIDialOut_PublishClient, error)
}

func NewGNMIDialOutClient

func NewGNMIDialOutClient(cc *grpc.ClientConn) GNMIDialOutClient

type GNMIDialOutServer

type GNMIDialOutServer interface {
	// Publish allows the target to send telemetry updates (in the form of
	// SubscribeResponse messaages, which have the same semantics as in the
	// gNMI Subscribe RPC, to a client. The client may optionally return the
	// PublishResponse message in response to the dial-out connection from the
	// target as acknowledgement to the SubscribeResponse message
	//
	// The configuration of subscriptions associated with the publish RPC may
	// be through the OpenConfig telemetry configuration and operational state
	// model:
	// https://github.com/openconfig/public/blob/master/release/models/telemetry/openconfig-telemetry.yang
	Publish(GNMIDialOut_PublishServer) error
}

type GNMIDialOut_PublishClient

type GNMIDialOut_PublishClient interface {
	Send(*gnmi.SubscribeResponse) error
	Recv() (*PublishResponse, error)
	grpc.ClientStream
}

type GNMIDialOut_PublishServer

type GNMIDialOut_PublishServer interface {
	Send(*PublishResponse) error
	Recv() (*gnmi.SubscribeResponse, error)
	grpc.ServerStream
}

type PublishResponse

type PublishResponse struct {
	Timestamp int64      `protobuf:"varint,1,opt,name=timestamp" json:"timestamp,omitempty"`
	Prefix    *gnmi.Path `protobuf:"bytes,2,opt,name=prefix" json:"prefix,omitempty"`
	// An alias for the path specified in the prefix field.
	// Reference: gNMI Specification Section 2.4.2
	Alias string       `protobuf:"bytes,3,opt,name=alias" json:"alias,omitempty"`
	Path  []*gnmi.Path `protobuf:"bytes,4,rep,name=path" json:"path,omitempty"`
}

func (*PublishResponse) Descriptor

func (*PublishResponse) Descriptor() ([]byte, []int)

func (*PublishResponse) GetAlias

func (m *PublishResponse) GetAlias() string

func (*PublishResponse) GetPath

func (m *PublishResponse) GetPath() []*gnmi.Path

func (*PublishResponse) GetPrefix

func (m *PublishResponse) GetPrefix() *gnmi.Path

func (*PublishResponse) GetTimestamp

func (m *PublishResponse) GetTimestamp() int64

func (*PublishResponse) ProtoMessage

func (*PublishResponse) ProtoMessage()

func (*PublishResponse) Reset

func (m *PublishResponse) Reset()

func (*PublishResponse) String

func (m *PublishResponse) String() string

type State

type State int32
const (
	State_STOPPED State = 0
	State_INIT    State = 1
	State_RUNNING State = 2
)

func (State) EnumDescriptor

func (State) EnumDescriptor() ([]byte, []int)

func (State) String

func (x State) String() string

type Target

type Target int32

target - the name of the target for which the path is a member. Only set in prefix for a path.

const (
	Target_APPL_DB     Target = 0
	Target_ASIC_DB     Target = 1
	Target_COUNTERS_DB Target = 2
	Target_LOGLEVEL_DB Target = 3
	Target_CONFIG_DB   Target = 4
	// PFC_WD_DB shares the the same db number with FLEX_COUNTER_DB
	Target_PFC_WD_DB       Target = 5
	Target_FLEX_COUNTER_DB Target = 5
	Target_STATE_DB        Target = 6
	// For none-DB data
	Target_OTHERS Target = 100
)

func (Target) EnumDescriptor

func (Target) EnumDescriptor() ([]byte, []int)

func (Target) String

func (x Target) String() string

type Value

type Value struct {
	// prefix used with path
	Prefix *gnmi.Path `protobuf:"bytes,1,opt,name=prefix" json:"prefix,omitempty"`
	// The device specific, or path corresponding to a value.
	Path *gnmi.Path `protobuf:"bytes,2,opt,name=path" json:"path,omitempty"`
	// timestamp for the corresponding value, nanoseconds since epoch.
	// If timestamp is not set the default will assume to
	// be the current system time.
	Timestamp int64            `protobuf:"varint,3,opt,name=timestamp" json:"timestamp,omitempty"`
	Val       *gnmi.TypedValue `protobuf:"bytes,4,opt,name=val" json:"val,omitempty"`
	// Indicate target has sent all values associated with the subscription
	// at least once.
	SyncResponse bool `protobuf:"varint,5,opt,name=sync_response,json=syncResponse" json:"sync_response,omitempty"`
	// fatal error happened.
	Fatal string `protobuf:"bytes,6,opt,name=fatal" json:"fatal,omitempty"`
}

Value is the message that reprents a stream of updates for a given path, used internally.

func (*Value) Descriptor

func (*Value) Descriptor() ([]byte, []int)

func (*Value) GetFatal

func (m *Value) GetFatal() string

func (*Value) GetPath

func (m *Value) GetPath() *gnmi.Path

func (*Value) GetPrefix

func (m *Value) GetPrefix() *gnmi.Path

func (*Value) GetSyncResponse

func (m *Value) GetSyncResponse() bool

func (*Value) GetTimestamp

func (m *Value) GetTimestamp() int64

func (*Value) GetVal

func (m *Value) GetVal() *gnmi.TypedValue

func (*Value) ProtoMessage

func (*Value) ProtoMessage()

func (*Value) Reset

func (m *Value) Reset()

func (*Value) String

func (m *Value) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL