configpb

package
v0.1.19 Latest Latest
Warning

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

Go to latest
Published: Aug 13, 2021 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Status_ResourceStatus_name = map[int32]string{
		0: "None",
		1: "Success",
		2: "Failed",
		3: "CreatePending",
		4: "UpdatePending",
		5: "DeletePending",
	}
	Status_ResourceStatus_value = map[string]int32{
		"None":          0,
		"Success":       1,
		"Failed":        2,
		"CreatePending": 3,
		"UpdatePending": 4,
		"DeletePending": 5,
	}
)

Enum value maps for Status_ResourceStatus.

View Source
var Configuration_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "config.Configuration",
	HandlerType: (*ConfigurationServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Create",
			Handler:    _Configuration_Create_Handler,
		},
		{
			MethodName: "Get",
			Handler:    _Configuration_Get_Handler,
		},
		{
			MethodName: "Update",
			Handler:    _Configuration_Update_Handler,
		},
		{
			MethodName: "Delete",
			Handler:    _Configuration_Delete_Handler,
		},
		{
			MethodName: "GetConfig",
			Handler:    _Configuration_GetConfig_Handler,
		},
		{
			MethodName: "GetResourceName",
			Handler:    _Configuration_GetResourceName_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "config/configpb/config.proto",
}

Configuration_ServiceDesc is the grpc.ServiceDesc for Configuration service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_config_configpb_config_proto protoreflect.FileDescriptor

Functions

func RegisterConfigurationServer

func RegisterConfigurationServer(s grpc.ServiceRegistrar, srv ConfigurationServer)

Types

type Attribute added in v0.1.19

type Attribute struct {
	ElemType  string   `protobuf:"bytes,1,opt,name=elemType,proto3" json:"elemType,omitempty"`
	Enum      []string `protobuf:"bytes,2,rep,name=enum,proto3" json:"enum,omitempty"`
	Range     []int32  `protobuf:"varint,3,rep,packed,name=range,proto3" json:"range,omitempty"`
	Length    []int32  `protobuf:"varint,4,rep,packed,name=length,proto3" json:"length,omitempty"`
	Pattern   []string `protobuf:"bytes,5,rep,name=pattern,proto3" json:"pattern,omitempty"`
	Union     bool     `protobuf:"varint,6,opt,name=union,proto3" json:"union,omitempty"`
	Mandatory bool     `protobuf:"varint,7,opt,name=mandatory,proto3" json:"mandatory,omitempty"`
	Default   string   `protobuf:"bytes,8,opt,name=default,proto3" json:"default,omitempty"`
	// contains filtered or unexported fields
}

Attaribute is used for code generation

func (*Attribute) Descriptor deprecated added in v0.1.19

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

Deprecated: Use Attribute.ProtoReflect.Descriptor instead.

func (*Attribute) GetDefault added in v0.1.19

func (x *Attribute) GetDefault() string

func (*Attribute) GetElemType added in v0.1.19

func (x *Attribute) GetElemType() string

func (*Attribute) GetEnum added in v0.1.19

func (x *Attribute) GetEnum() []string

func (*Attribute) GetLength added in v0.1.19

func (x *Attribute) GetLength() []int32

func (*Attribute) GetMandatory added in v0.1.19

func (x *Attribute) GetMandatory() bool

func (*Attribute) GetPattern added in v0.1.19

func (x *Attribute) GetPattern() []string

func (*Attribute) GetRange added in v0.1.19

func (x *Attribute) GetRange() []int32

func (*Attribute) GetUnion added in v0.1.19

func (x *Attribute) GetUnion() bool

func (*Attribute) ProtoMessage added in v0.1.19

func (*Attribute) ProtoMessage()

func (*Attribute) ProtoReflect added in v0.1.19

func (x *Attribute) ProtoReflect() protoreflect.Message

func (*Attribute) Reset added in v0.1.19

func (x *Attribute) Reset()

func (*Attribute) String added in v0.1.19

func (x *Attribute) String() string

type ConfigReply added in v0.1.19

type ConfigReply struct {
	Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*ConfigReply) Descriptor deprecated added in v0.1.19

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

Deprecated: Use ConfigReply.ProtoReflect.Descriptor instead.

func (*ConfigReply) GetData added in v0.1.19

func (x *ConfigReply) GetData() []byte

func (*ConfigReply) ProtoMessage added in v0.1.19

func (*ConfigReply) ProtoMessage()

func (*ConfigReply) ProtoReflect added in v0.1.19

func (x *ConfigReply) ProtoReflect() protoreflect.Message

func (*ConfigReply) Reset added in v0.1.19

func (x *ConfigReply) Reset()

func (*ConfigReply) String added in v0.1.19

func (x *ConfigReply) String() string

type ConfigRequest added in v0.1.19

type ConfigRequest struct {
	// contains filtered or unexported fields
}

func (*ConfigRequest) Descriptor deprecated added in v0.1.19

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

Deprecated: Use ConfigRequest.ProtoReflect.Descriptor instead.

func (*ConfigRequest) ProtoMessage added in v0.1.19

func (*ConfigRequest) ProtoMessage()

func (*ConfigRequest) ProtoReflect added in v0.1.19

func (x *ConfigRequest) ProtoReflect() protoreflect.Message

func (*ConfigRequest) Reset added in v0.1.19

func (x *ConfigRequest) Reset()

func (*ConfigRequest) String added in v0.1.19

func (x *ConfigRequest) String() string

type ConfigurationClient

type ConfigurationClient interface {
	Create(ctx context.Context, in *Request, opts ...grpc.CallOption) (*Reply, error)
	Get(ctx context.Context, in *ResourceKey, opts ...grpc.CallOption) (*Status, error)
	Update(ctx context.Context, in *Request, opts ...grpc.CallOption) (*Reply, error)
	Delete(ctx context.Context, in *ResourceKey, opts ...grpc.CallOption) (*Reply, error)
	GetConfig(ctx context.Context, in *ConfigRequest, opts ...grpc.CallOption) (*ConfigReply, error)
	GetResourceName(ctx context.Context, in *ResourceRequest, opts ...grpc.CallOption) (*ResourceReply, error)
}

ConfigurationClient is the client API for Configuration service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type ConfigurationServer

type ConfigurationServer interface {
	Create(context.Context, *Request) (*Reply, error)
	Get(context.Context, *ResourceKey) (*Status, error)
	Update(context.Context, *Request) (*Reply, error)
	Delete(context.Context, *ResourceKey) (*Reply, error)
	GetConfig(context.Context, *ConfigRequest) (*ConfigReply, error)
	GetResourceName(context.Context, *ResourceRequest) (*ResourceReply, error)
	// contains filtered or unexported methods
}

ConfigurationServer is the server API for Configuration service. All implementations must embed UnimplementedConfigurationServer for forward compatibility

type Deviation added in v0.1.19

type Deviation struct {
	Path  *Path  `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*Deviation) Descriptor deprecated added in v0.1.19

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

Deprecated: Use Deviation.ProtoReflect.Descriptor instead.

func (*Deviation) GetPath added in v0.1.19

func (x *Deviation) GetPath() *Path

func (*Deviation) GetValue added in v0.1.19

func (x *Deviation) GetValue() string

func (*Deviation) ProtoMessage added in v0.1.19

func (*Deviation) ProtoMessage()

func (*Deviation) ProtoReflect added in v0.1.19

func (x *Deviation) ProtoReflect() protoreflect.Message

func (*Deviation) Reset added in v0.1.19

func (x *Deviation) Reset()

func (*Deviation) String added in v0.1.19

func (x *Deviation) String() string

type Path added in v0.1.19

type Path struct {
	Elem []*PathElem `protobuf:"bytes,3,rep,name=elem,proto3" json:"elem,omitempty"` // Elements of the path.
	// contains filtered or unexported fields
}

Path encodes a data tree path as a series of repeated strings, with each element of the path representing a data tree node name and the associated attributes. Reference: gNMI Specification Section 2.2.2.

func (*Path) Descriptor deprecated added in v0.1.19

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

Deprecated: Use Path.ProtoReflect.Descriptor instead.

func (*Path) GetElem added in v0.1.19

func (x *Path) GetElem() []*PathElem

func (*Path) ProtoMessage added in v0.1.19

func (*Path) ProtoMessage()

func (*Path) ProtoReflect added in v0.1.19

func (x *Path) ProtoReflect() protoreflect.Message

func (*Path) Reset added in v0.1.19

func (x *Path) Reset()

func (*Path) String added in v0.1.19

func (x *Path) String() string

type PathElem added in v0.1.19

type PathElem struct {
	Name string            `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // The name of the element in the path.
	Key  map[string]string ``                                                              // Map of key (attribute) name to value.
	/* 147-byte string literal not displayed */
	Attribute *Attribute `protobuf:"bytes,3,opt,name=attribute,proto3" json:"attribute,omitempty"`
	// contains filtered or unexported fields
}

PathElem encodes an element of a path, along with any attributes (keys) that may be associated with it.

func (*PathElem) Descriptor deprecated added in v0.1.19

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

Deprecated: Use PathElem.ProtoReflect.Descriptor instead.

func (*PathElem) GetAttribute added in v0.1.19

func (x *PathElem) GetAttribute() *Attribute

func (*PathElem) GetKey added in v0.1.19

func (x *PathElem) GetKey() map[string]string

func (*PathElem) GetName added in v0.1.19

func (x *PathElem) GetName() string

func (*PathElem) ProtoMessage added in v0.1.19

func (*PathElem) ProtoMessage()

func (*PathElem) ProtoReflect added in v0.1.19

func (x *PathElem) ProtoReflect() protoreflect.Message

func (*PathElem) Reset added in v0.1.19

func (x *PathElem) Reset()

func (*PathElem) String added in v0.1.19

func (x *PathElem) String() string

type Reply added in v0.1.19

type Reply struct {
	// contains filtered or unexported fields
}

func (*Reply) Descriptor deprecated added in v0.1.19

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

Deprecated: Use Reply.ProtoReflect.Descriptor instead.

func (*Reply) ProtoMessage added in v0.1.19

func (*Reply) ProtoMessage()

func (*Reply) ProtoReflect added in v0.1.19

func (x *Reply) ProtoReflect() protoreflect.Message

func (*Reply) Reset added in v0.1.19

func (x *Reply) Reset()

func (*Reply) String added in v0.1.19

func (x *Reply) String() string

type Request added in v0.1.19

type Request struct {
	Name  string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Level int32  `protobuf:"varint,2,opt,name=level,proto3" json:"level,omitempty"`
	Path  *Path  `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"`
	Data  []byte `protobuf:"bytes,5,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*Request) Descriptor deprecated added in v0.1.19

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

Deprecated: Use Request.ProtoReflect.Descriptor instead.

func (*Request) GetData added in v0.1.19

func (x *Request) GetData() []byte

func (*Request) GetLevel added in v0.1.19

func (x *Request) GetLevel() int32

func (*Request) GetName added in v0.1.19

func (x *Request) GetName() string

func (*Request) GetPath added in v0.1.19

func (x *Request) GetPath() *Path

func (*Request) ProtoMessage added in v0.1.19

func (*Request) ProtoMessage()

func (*Request) ProtoReflect added in v0.1.19

func (x *Request) ProtoReflect() protoreflect.Message

func (*Request) Reset added in v0.1.19

func (x *Request) Reset()

func (*Request) String added in v0.1.19

func (x *Request) String() string

type ResourceKey added in v0.1.19

type ResourceKey struct {
	Name  string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Level int32  `protobuf:"varint,2,opt,name=level,proto3" json:"level,omitempty"`
	// contains filtered or unexported fields
}

func (*ResourceKey) Descriptor deprecated added in v0.1.19

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

Deprecated: Use ResourceKey.ProtoReflect.Descriptor instead.

func (*ResourceKey) GetLevel added in v0.1.19

func (x *ResourceKey) GetLevel() int32

func (*ResourceKey) GetName added in v0.1.19

func (x *ResourceKey) GetName() string

func (*ResourceKey) ProtoMessage added in v0.1.19

func (*ResourceKey) ProtoMessage()

func (*ResourceKey) ProtoReflect added in v0.1.19

func (x *ResourceKey) ProtoReflect() protoreflect.Message

func (*ResourceKey) Reset added in v0.1.19

func (x *ResourceKey) Reset()

func (*ResourceKey) String added in v0.1.19

func (x *ResourceKey) String() string

type ResourceReply added in v0.1.19

type ResourceReply struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*ResourceReply) Descriptor deprecated added in v0.1.19

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

Deprecated: Use ResourceReply.ProtoReflect.Descriptor instead.

func (*ResourceReply) GetName added in v0.1.19

func (x *ResourceReply) GetName() string

func (*ResourceReply) ProtoMessage added in v0.1.19

func (*ResourceReply) ProtoMessage()

func (*ResourceReply) ProtoReflect added in v0.1.19

func (x *ResourceReply) ProtoReflect() protoreflect.Message

func (*ResourceReply) Reset added in v0.1.19

func (x *ResourceReply) Reset()

func (*ResourceReply) String added in v0.1.19

func (x *ResourceReply) String() string

type ResourceRequest added in v0.1.19

type ResourceRequest struct {
	Path *Path `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	// contains filtered or unexported fields
}

func (*ResourceRequest) Descriptor deprecated added in v0.1.19

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

Deprecated: Use ResourceRequest.ProtoReflect.Descriptor instead.

func (*ResourceRequest) GetPath added in v0.1.19

func (x *ResourceRequest) GetPath() *Path

func (*ResourceRequest) ProtoMessage added in v0.1.19

func (*ResourceRequest) ProtoMessage()

func (*ResourceRequest) ProtoReflect added in v0.1.19

func (x *ResourceRequest) ProtoReflect() protoreflect.Message

func (*ResourceRequest) Reset added in v0.1.19

func (x *ResourceRequest) Reset()

func (*ResourceRequest) String added in v0.1.19

func (x *ResourceRequest) String() string

type Status added in v0.1.19

type Status struct {
	Name      string                `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Level     int32                 `protobuf:"varint,2,opt,name=level,proto3" json:"level,omitempty"`
	Path      *Path                 `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"`
	Data      []byte                `protobuf:"bytes,4,opt,name=data,proto3" json:"data,omitempty"`
	Status    Status_ResourceStatus `protobuf:"varint,5,opt,name=status,proto3,enum=config.Status_ResourceStatus" json:"status,omitempty"`
	Deviation []*Deviation          `protobuf:"bytes,6,rep,name=deviation,proto3" json:"deviation,omitempty"`
	Exists    bool                  `protobuf:"varint,7,opt,name=exists,proto3" json:"exists,omitempty"`
	// contains filtered or unexported fields
}

func (*Status) Descriptor deprecated added in v0.1.19

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

Deprecated: Use Status.ProtoReflect.Descriptor instead.

func (*Status) GetData added in v0.1.19

func (x *Status) GetData() []byte

func (*Status) GetDeviation added in v0.1.19

func (x *Status) GetDeviation() []*Deviation

func (*Status) GetExists added in v0.1.19

func (x *Status) GetExists() bool

func (*Status) GetLevel added in v0.1.19

func (x *Status) GetLevel() int32

func (*Status) GetName added in v0.1.19

func (x *Status) GetName() string

func (*Status) GetPath added in v0.1.19

func (x *Status) GetPath() *Path

func (*Status) GetStatus added in v0.1.19

func (x *Status) GetStatus() Status_ResourceStatus

func (*Status) ProtoMessage added in v0.1.19

func (*Status) ProtoMessage()

func (*Status) ProtoReflect added in v0.1.19

func (x *Status) ProtoReflect() protoreflect.Message

func (*Status) Reset added in v0.1.19

func (x *Status) Reset()

func (*Status) String added in v0.1.19

func (x *Status) String() string

type Status_ResourceStatus added in v0.1.19

type Status_ResourceStatus int32
const (
	Status_None          Status_ResourceStatus = 0
	Status_Success       Status_ResourceStatus = 1
	Status_Failed        Status_ResourceStatus = 2
	Status_CreatePending Status_ResourceStatus = 3
	Status_UpdatePending Status_ResourceStatus = 4
	Status_DeletePending Status_ResourceStatus = 5
)

func (Status_ResourceStatus) Descriptor added in v0.1.19

func (Status_ResourceStatus) Enum added in v0.1.19

func (Status_ResourceStatus) EnumDescriptor deprecated added in v0.1.19

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

Deprecated: Use Status_ResourceStatus.Descriptor instead.

func (Status_ResourceStatus) Number added in v0.1.19

func (Status_ResourceStatus) String added in v0.1.19

func (x Status_ResourceStatus) String() string

func (Status_ResourceStatus) Type added in v0.1.19

type UnimplementedConfigurationServer

type UnimplementedConfigurationServer struct {
}

UnimplementedConfigurationServer must be embedded to have forward compatible implementations.

func (UnimplementedConfigurationServer) Create

func (UnimplementedConfigurationServer) Delete

func (UnimplementedConfigurationServer) Get

func (UnimplementedConfigurationServer) GetConfig added in v0.1.19

func (UnimplementedConfigurationServer) GetResourceName added in v0.1.19

func (UnimplementedConfigurationServer) Update

type UnsafeConfigurationServer

type UnsafeConfigurationServer interface {
	// contains filtered or unexported methods
}

UnsafeConfigurationServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ConfigurationServer will result in compilation errors.

Jump to

Keyboard shortcuts

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