lancergateway

package
v0.0.0-...-83adff0 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2020 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Overview

Package StreamEvent is a generated protocol buffer package.

It is generated from these files:

app/service/ops/log-agent/output/lancergrpc/lancergateway/StreamEvent.proto

It has these top-level messages:

SimpleEvent
EventList
Response

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthStreamEvent = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowStreamEvent   = fmt.Errorf("proto: integer overflow")
)
View Source
var StatusCode_name = map[int32]string{
	0:   "NULL",
	200: "SUCCESS",
	429: "LOAD_FULL",
}
View Source
var StatusCode_value = map[string]int32{
	"NULL":      0,
	"SUCCESS":   200,
	"LOAD_FULL": 429,
}

Functions

func RegisterGateway2ServerServer

func RegisterGateway2ServerServer(s *grpc.Server, srv Gateway2ServerServer)

Types

type Config

type Config struct {
	AppId   string         `toml:"appId"`
	Timeout xtime.Duration `toml:"timeout"`
	Subset  int            `toml:"subset"`
}

func (*Config) ConfigValidate

func (c *Config) ConfigValidate() error

type EventList

type EventList struct {
	Events []*SimpleEvent `protobuf:"bytes,1,rep,name=events" json:"events,omitempty"`
}

func (*EventList) Descriptor

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

func (*EventList) GetEvents

func (m *EventList) GetEvents() []*SimpleEvent

func (*EventList) Marshal

func (m *EventList) Marshal() (dAtA []byte, err error)

func (*EventList) MarshalTo

func (m *EventList) MarshalTo(dAtA []byte) (int, error)

func (*EventList) ProtoMessage

func (*EventList) ProtoMessage()

func (*EventList) Reset

func (m *EventList) Reset()

func (*EventList) Size

func (m *EventList) Size() (n int)

func (*EventList) String

func (m *EventList) String() string

func (*EventList) Unmarshal

func (m *EventList) Unmarshal(dAtA []byte) error

type Gateway2ServerClient

type Gateway2ServerClient interface {
	SendList(ctx context.Context, in *EventList, opts ...grpc.CallOption) (*Response, error)
	Send(ctx context.Context, in *SimpleEvent, opts ...grpc.CallOption) (*Response, error)
}

func NewClient

func NewClient(c *Config) (Gateway2ServerClient, error)

NewClient new member grpc client

func NewGateway2ServerClient

func NewGateway2ServerClient(cc *grpc.ClientConn) Gateway2ServerClient

type Gateway2ServerServer

type Gateway2ServerServer interface {
	SendList(context.Context, *EventList) (*Response, error)
	Send(context.Context, *SimpleEvent) (*Response, error)
}

type Response

type Response struct {
	Code StatusCode `protobuf:"varint,1,opt,name=code,proto3,enum=StatusCode" json:"code,omitempty"`
	Msg  string     `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"`
}

func (*Response) Descriptor

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

func (*Response) GetCode

func (m *Response) GetCode() StatusCode

func (*Response) GetMsg

func (m *Response) GetMsg() string

func (*Response) Marshal

func (m *Response) Marshal() (dAtA []byte, err error)

func (*Response) MarshalTo

func (m *Response) MarshalTo(dAtA []byte) (int, error)

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) Reset

func (m *Response) Reset()

func (*Response) Size

func (m *Response) Size() (n int)

func (*Response) String

func (m *Response) String() string

func (*Response) Unmarshal

func (m *Response) Unmarshal(dAtA []byte) error

type SimpleEvent

type SimpleEvent struct {
	LogId   string            `protobuf:"bytes,1,opt,name=logId,proto3" json:"logId,omitempty"`
	OuterId string            `protobuf:"bytes,2,opt,name=outerId,proto3" json:"outerId,omitempty"`
	Header  map[string]string `` /* 146-byte string literal not displayed */
	Data    []byte            `protobuf:"bytes,4,opt,name=data,proto3" json:"data,omitempty"`
}

func (*SimpleEvent) Descriptor

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

func (*SimpleEvent) GetData

func (m *SimpleEvent) GetData() []byte

func (*SimpleEvent) GetHeader

func (m *SimpleEvent) GetHeader() map[string]string

func (*SimpleEvent) GetLogId

func (m *SimpleEvent) GetLogId() string

func (*SimpleEvent) GetOuterId

func (m *SimpleEvent) GetOuterId() string

func (*SimpleEvent) Marshal

func (m *SimpleEvent) Marshal() (dAtA []byte, err error)

func (*SimpleEvent) MarshalTo

func (m *SimpleEvent) MarshalTo(dAtA []byte) (int, error)

func (*SimpleEvent) ProtoMessage

func (*SimpleEvent) ProtoMessage()

func (*SimpleEvent) Reset

func (m *SimpleEvent) Reset()

func (*SimpleEvent) Size

func (m *SimpleEvent) Size() (n int)

func (*SimpleEvent) String

func (m *SimpleEvent) String() string

func (*SimpleEvent) Unmarshal

func (m *SimpleEvent) Unmarshal(dAtA []byte) error

type StatusCode

type StatusCode int32
const (
	StatusCode_NULL      StatusCode = 0
	StatusCode_SUCCESS   StatusCode = 200
	StatusCode_LOAD_FULL StatusCode = 429
)

func (StatusCode) EnumDescriptor

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

func (StatusCode) String

func (x StatusCode) String() string

Jump to

Keyboard shortcuts

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