pb

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var HandlerType_name = map[int32]string{
	0: "UNKNOWN_HANDLER_TYPE",
	1: "AGGREGATE",
	2: "PROCESS",
	3: "INTEGRATION",
	4: "PROJECTION",
}
View Source
var HandlerType_value = map[string]int32{
	"UNKNOWN_HANDLER_TYPE": 0,
	"AGGREGATE":            1,
	"PROCESS":              2,
	"INTEGRATION":          3,
	"PROJECTION":           4,
}
View Source
var MessageRole_name = map[int32]string{
	0: "UNKNOWN_MESSAGE_ROLE",
	1: "COMMAND",
	2: "EVENT",
	3: "TIMEOUT",
}
View Source
var MessageRole_value = map[string]int32{
	"UNKNOWN_MESSAGE_ROLE": 0,
	"COMMAND":              1,
	"EVENT":                2,
	"TIMEOUT":              3,
}

Functions

func RegisterConfigServer

func RegisterConfigServer(s *grpc.Server, srv ConfigServer)

Types

type Application

type Application struct {
	// Identity is the application's identity.
	Identity *Identity `protobuf:"bytes,1,opt,name=identity,proto3" json:"identity,omitempty"`
	// TypeName is the fully-qualified name of the Go type used to implement the
	// application.
	TypeName string `protobuf:"bytes,2,opt,name=type_name,json=typeName,proto3" json:"type_name,omitempty"`
	// Messages is an ordered-sequence of message name / role pairs.
	//
	// This directly correlates to the configkit.Application.MessageNames().Roles
	// value. The produced/consumed message names are not encoded directly in the
	// application, but rather rebuilt from the handlers when the application is
	// unmarshaled.
	Messages []*NameRole `protobuf:"bytes,3,rep,name=messages,proto3" json:"messages,omitempty"`
	// Handlers is the set of handlers within the application.
	Handlers             []*Handler `protobuf:"bytes,4,rep,name=handlers,proto3" json:"handlers,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

Application is a protocol buffers representation of the configkit.Application interface.

func (*Application) Descriptor

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

func (*Application) GetHandlers

func (m *Application) GetHandlers() []*Handler

func (*Application) GetIdentity

func (m *Application) GetIdentity() *Identity

func (*Application) GetMessages

func (m *Application) GetMessages() []*NameRole

func (*Application) GetTypeName

func (m *Application) GetTypeName() string

func (*Application) ProtoMessage

func (*Application) ProtoMessage()

func (*Application) Reset

func (m *Application) Reset()

func (*Application) String

func (m *Application) String() string

func (*Application) XXX_DiscardUnknown

func (m *Application) XXX_DiscardUnknown()

func (*Application) XXX_Marshal

func (m *Application) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Application) XXX_Merge

func (m *Application) XXX_Merge(src proto.Message)

func (*Application) XXX_Size

func (m *Application) XXX_Size() int

func (*Application) XXX_Unmarshal

func (m *Application) XXX_Unmarshal(b []byte) error

type ConfigClient

type ConfigClient interface {
	// ListApplicationIdentities returns the identity of all applications.
	ListApplicationIdentities(ctx context.Context, in *ListApplicationIdentitiesRequest, opts ...grpc.CallOption) (*ListApplicationIdentitiesResponse, error)
	// ListApplications returns the full configuration of all applications.
	ListApplications(ctx context.Context, in *ListApplicationsRequest, opts ...grpc.CallOption) (*ListApplicationsResponse, error)
}

ConfigClient is the client API for Config service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewConfigClient

func NewConfigClient(cc grpc.ClientConnInterface) ConfigClient

type ConfigServer

type ConfigServer interface {
	// ListApplicationIdentities returns the identity of all applications.
	ListApplicationIdentities(context.Context, *ListApplicationIdentitiesRequest) (*ListApplicationIdentitiesResponse, error)
	// ListApplications returns the full configuration of all applications.
	ListApplications(context.Context, *ListApplicationsRequest) (*ListApplicationsResponse, error)
}

ConfigServer is the server API for Config service.

type Handler

type Handler struct {
	// Identity is the handler's identity.
	Identity *Identity `protobuf:"bytes,1,opt,name=identity,proto3" json:"identity,omitempty"`
	// TypeName is the fully-qualified name of the Go type used to implement the
	// handler.
	TypeName string `protobuf:"bytes,2,opt,name=type_name,json=typeName,proto3" json:"type_name,omitempty"`
	// Type is the handler's type.
	Type HandlerType `protobuf:"varint,3,opt,name=type,proto3,enum=dogma.configapi.v1.HandlerType" json:"type,omitempty"`
	// Produced is a list of the messages produced by this handler.
	// Each value is the index of a MessageRolePair within the application.
	Produced []uint32 `protobuf:"varint,4,rep,packed,name=produced,proto3" json:"produced,omitempty"`
	// Consumed is a list of the messages consumed by this handler.
	// Each value is the index of a MessageRolePair within the application.
	Consumed             []uint32 `protobuf:"varint,5,rep,packed,name=consumed,proto3" json:"consumed,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

Handler is a protocol buffers representation of the configkit.Handler interface.

func (*Handler) Descriptor

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

func (*Handler) GetConsumed

func (m *Handler) GetConsumed() []uint32

func (*Handler) GetIdentity

func (m *Handler) GetIdentity() *Identity

func (*Handler) GetProduced

func (m *Handler) GetProduced() []uint32

func (*Handler) GetType

func (m *Handler) GetType() HandlerType

func (*Handler) GetTypeName

func (m *Handler) GetTypeName() string

func (*Handler) ProtoMessage

func (*Handler) ProtoMessage()

func (*Handler) Reset

func (m *Handler) Reset()

func (*Handler) String

func (m *Handler) String() string

func (*Handler) XXX_DiscardUnknown

func (m *Handler) XXX_DiscardUnknown()

func (*Handler) XXX_Marshal

func (m *Handler) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Handler) XXX_Merge

func (m *Handler) XXX_Merge(src proto.Message)

func (*Handler) XXX_Size

func (m *Handler) XXX_Size() int

func (*Handler) XXX_Unmarshal

func (m *Handler) XXX_Unmarshal(b []byte) error

type HandlerType

type HandlerType int32

HandlerType is a protocol buffers representation of the configkit.HandlerType enumeration.

const (
	HandlerType_UNKNOWN_HANDLER_TYPE HandlerType = 0
	HandlerType_AGGREGATE            HandlerType = 1
	HandlerType_PROCESS              HandlerType = 2
	HandlerType_INTEGRATION          HandlerType = 3
	HandlerType_PROJECTION           HandlerType = 4
)

func (HandlerType) EnumDescriptor

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

func (HandlerType) String

func (x HandlerType) String() string

type Identity

type Identity struct {
	// Name is the entity's unique name.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Key is the entity's immutable, unique key.
	Key                  string   `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

Identity is a protocol buffers representation of the configkit.Identity type.

func (*Identity) Descriptor

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

func (*Identity) GetKey

func (m *Identity) GetKey() string

func (*Identity) GetName

func (m *Identity) GetName() string

func (*Identity) ProtoMessage

func (*Identity) ProtoMessage()

func (*Identity) Reset

func (m *Identity) Reset()

func (*Identity) String

func (m *Identity) String() string

func (*Identity) XXX_DiscardUnknown

func (m *Identity) XXX_DiscardUnknown()

func (*Identity) XXX_Marshal

func (m *Identity) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Identity) XXX_Merge

func (m *Identity) XXX_Merge(src proto.Message)

func (*Identity) XXX_Size

func (m *Identity) XXX_Size() int

func (*Identity) XXX_Unmarshal

func (m *Identity) XXX_Unmarshal(b []byte) error

type ListApplicationIdentitiesRequest

type ListApplicationIdentitiesRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ListApplicationIdentitiesRequest) Descriptor

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

func (*ListApplicationIdentitiesRequest) ProtoMessage

func (*ListApplicationIdentitiesRequest) ProtoMessage()

func (*ListApplicationIdentitiesRequest) Reset

func (*ListApplicationIdentitiesRequest) String

func (*ListApplicationIdentitiesRequest) XXX_DiscardUnknown

func (m *ListApplicationIdentitiesRequest) XXX_DiscardUnknown()

func (*ListApplicationIdentitiesRequest) XXX_Marshal

func (m *ListApplicationIdentitiesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ListApplicationIdentitiesRequest) XXX_Merge

func (*ListApplicationIdentitiesRequest) XXX_Size

func (m *ListApplicationIdentitiesRequest) XXX_Size() int

func (*ListApplicationIdentitiesRequest) XXX_Unmarshal

func (m *ListApplicationIdentitiesRequest) XXX_Unmarshal(b []byte) error

type ListApplicationIdentitiesResponse

type ListApplicationIdentitiesResponse struct {
	Identities           []*Identity `protobuf:"bytes,1,rep,name=identities,proto3" json:"identities,omitempty"`
	XXX_NoUnkeyedLiteral struct{}    `json:"-"`
	XXX_unrecognized     []byte      `json:"-"`
	XXX_sizecache        int32       `json:"-"`
}

func (*ListApplicationIdentitiesResponse) Descriptor

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

func (*ListApplicationIdentitiesResponse) GetIdentities

func (m *ListApplicationIdentitiesResponse) GetIdentities() []*Identity

func (*ListApplicationIdentitiesResponse) ProtoMessage

func (*ListApplicationIdentitiesResponse) ProtoMessage()

func (*ListApplicationIdentitiesResponse) Reset

func (*ListApplicationIdentitiesResponse) String

func (*ListApplicationIdentitiesResponse) XXX_DiscardUnknown

func (m *ListApplicationIdentitiesResponse) XXX_DiscardUnknown()

func (*ListApplicationIdentitiesResponse) XXX_Marshal

func (m *ListApplicationIdentitiesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ListApplicationIdentitiesResponse) XXX_Merge

func (*ListApplicationIdentitiesResponse) XXX_Size

func (m *ListApplicationIdentitiesResponse) XXX_Size() int

func (*ListApplicationIdentitiesResponse) XXX_Unmarshal

func (m *ListApplicationIdentitiesResponse) XXX_Unmarshal(b []byte) error

type ListApplicationsRequest

type ListApplicationsRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ListApplicationsRequest) Descriptor

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

func (*ListApplicationsRequest) ProtoMessage

func (*ListApplicationsRequest) ProtoMessage()

func (*ListApplicationsRequest) Reset

func (m *ListApplicationsRequest) Reset()

func (*ListApplicationsRequest) String

func (m *ListApplicationsRequest) String() string

func (*ListApplicationsRequest) XXX_DiscardUnknown

func (m *ListApplicationsRequest) XXX_DiscardUnknown()

func (*ListApplicationsRequest) XXX_Marshal

func (m *ListApplicationsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ListApplicationsRequest) XXX_Merge

func (m *ListApplicationsRequest) XXX_Merge(src proto.Message)

func (*ListApplicationsRequest) XXX_Size

func (m *ListApplicationsRequest) XXX_Size() int

func (*ListApplicationsRequest) XXX_Unmarshal

func (m *ListApplicationsRequest) XXX_Unmarshal(b []byte) error

type ListApplicationsResponse

type ListApplicationsResponse struct {
	Applications         []*Application `protobuf:"bytes,1,rep,name=applications,proto3" json:"applications,omitempty"`
	XXX_NoUnkeyedLiteral struct{}       `json:"-"`
	XXX_unrecognized     []byte         `json:"-"`
	XXX_sizecache        int32          `json:"-"`
}

func (*ListApplicationsResponse) Descriptor

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

func (*ListApplicationsResponse) GetApplications

func (m *ListApplicationsResponse) GetApplications() []*Application

func (*ListApplicationsResponse) ProtoMessage

func (*ListApplicationsResponse) ProtoMessage()

func (*ListApplicationsResponse) Reset

func (m *ListApplicationsResponse) Reset()

func (*ListApplicationsResponse) String

func (m *ListApplicationsResponse) String() string

func (*ListApplicationsResponse) XXX_DiscardUnknown

func (m *ListApplicationsResponse) XXX_DiscardUnknown()

func (*ListApplicationsResponse) XXX_Marshal

func (m *ListApplicationsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ListApplicationsResponse) XXX_Merge

func (m *ListApplicationsResponse) XXX_Merge(src proto.Message)

func (*ListApplicationsResponse) XXX_Size

func (m *ListApplicationsResponse) XXX_Size() int

func (*ListApplicationsResponse) XXX_Unmarshal

func (m *ListApplicationsResponse) XXX_Unmarshal(b []byte) error

type MessageRole

type MessageRole int32

MessageRole is a protocol buffers representation of the configkit/message.Role enumeration.

const (
	MessageRole_UNKNOWN_MESSAGE_ROLE MessageRole = 0
	MessageRole_COMMAND              MessageRole = 1
	MessageRole_EVENT                MessageRole = 2
	MessageRole_TIMEOUT              MessageRole = 3
)

func (MessageRole) EnumDescriptor

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

func (MessageRole) String

func (x MessageRole) String() string

type NameRole

type NameRole struct {
	// Name is the fully-qualified message name.
	Name []byte `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Role is the role this message plays within the application.
	Role                 MessageRole `protobuf:"varint,2,opt,name=role,proto3,enum=dogma.configapi.v1.MessageRole" json:"role,omitempty"`
	XXX_NoUnkeyedLiteral struct{}    `json:"-"`
	XXX_unrecognized     []byte      `json:"-"`
	XXX_sizecache        int32       `json:"-"`
}

NameRole is a 2-tuple containing a message name and its role.

func (*NameRole) Descriptor

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

func (*NameRole) GetName

func (m *NameRole) GetName() []byte

func (*NameRole) GetRole

func (m *NameRole) GetRole() MessageRole

func (*NameRole) ProtoMessage

func (*NameRole) ProtoMessage()

func (*NameRole) Reset

func (m *NameRole) Reset()

func (*NameRole) String

func (m *NameRole) String() string

func (*NameRole) XXX_DiscardUnknown

func (m *NameRole) XXX_DiscardUnknown()

func (*NameRole) XXX_Marshal

func (m *NameRole) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*NameRole) XXX_Merge

func (m *NameRole) XXX_Merge(src proto.Message)

func (*NameRole) XXX_Size

func (m *NameRole) XXX_Size() int

func (*NameRole) XXX_Unmarshal

func (m *NameRole) XXX_Unmarshal(b []byte) error

type UnimplementedConfigServer

type UnimplementedConfigServer struct {
}

UnimplementedConfigServer can be embedded to have forward compatible implementations.

func (*UnimplementedConfigServer) ListApplicationIdentities

func (*UnimplementedConfigServer) ListApplications

Jump to

Keyboard shortcuts

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