LogPost

package
v0.0.0-...-1949622 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2017 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package LogPost is a generated protocol buffer package.

It is generated from these files:

log_post_service.proto

It has these top-level messages:

EmptyMessage
EpInfo
ConfigResp
LogMsg

Index

Constants

This section is empty.

Variables

View Source
var LogLevel_name = map[int32]string{
	0: "NOOP",
	1: "TRACE",
	2: "INFO",
	4: "ERROR",
	8: "FATAL",
}
View Source
var LogLevel_value = map[string]int32{
	"NOOP":  0,
	"TRACE": 1,
	"INFO":  2,
	"ERROR": 4,
	"FATAL": 8,
}

Functions

func RegisterLogPostServer

func RegisterLogPostServer(s *grpc.Server, srv LogPostServer)

Types

type ConfigResp

type ConfigResp struct {
	ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId" json:"client_id,omitempty"`
}

func (*ConfigResp) Descriptor

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

func (*ConfigResp) GetClientId

func (m *ConfigResp) GetClientId() string

func (*ConfigResp) ProtoMessage

func (*ConfigResp) ProtoMessage()

func (*ConfigResp) Reset

func (m *ConfigResp) Reset()

func (*ConfigResp) String

func (m *ConfigResp) String() string

type EmptyMessage

type EmptyMessage struct {
}

func (*EmptyMessage) Descriptor

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

func (*EmptyMessage) ProtoMessage

func (*EmptyMessage) ProtoMessage()

func (*EmptyMessage) Reset

func (m *EmptyMessage) Reset()

func (*EmptyMessage) String

func (m *EmptyMessage) String() string

type EpInfo

type EpInfo struct {
	ServiceName    string `protobuf:"bytes,1,opt,name=service_name,json=serviceName" json:"service_name,omitempty"`
	ServiceVersion string `protobuf:"bytes,2,opt,name=service_version,json=serviceVersion" json:"service_version,omitempty"`
	IpAddr         string `protobuf:"bytes,3,opt,name=ip_addr,json=ipAddr" json:"ip_addr,omitempty"`
	LogLevel       int32  `protobuf:"varint,4,opt,name=log_level,json=logLevel" json:"log_level,omitempty"`
	ClientId       string `protobuf:"bytes,5,opt,name=client_id,json=clientId" json:"client_id,omitempty"`
}

Message used to register client with the LogServer

func (*EpInfo) Descriptor

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

func (*EpInfo) GetClientId

func (m *EpInfo) GetClientId() string

func (*EpInfo) GetIpAddr

func (m *EpInfo) GetIpAddr() string

func (*EpInfo) GetLogLevel

func (m *EpInfo) GetLogLevel() int32

func (*EpInfo) GetServiceName

func (m *EpInfo) GetServiceName() string

func (*EpInfo) GetServiceVersion

func (m *EpInfo) GetServiceVersion() string

func (*EpInfo) ProtoMessage

func (*EpInfo) ProtoMessage()

func (*EpInfo) Reset

func (m *EpInfo) Reset()

func (*EpInfo) String

func (m *EpInfo) String() string

type LogLevel

type LogLevel int32
const (
	// Discard all logs
	LogLevel_NOOP LogLevel = 0
	// Tracing is turned on.
	LogLevel_TRACE LogLevel = 1
	// Info logs. Used to log information relevant to app.
	LogLevel_INFO LogLevel = 2
	// Used to log errors.
	LogLevel_ERROR LogLevel = 4
	// Used to fatal situations.
	LogLevel_FATAL LogLevel = 8
)

func (LogLevel) EnumDescriptor

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

func (LogLevel) String

func (x LogLevel) String() string

type LogMsg

type LogMsg struct {
	ClientId string   `protobuf:"bytes,1,opt,name=client_id,json=clientId" json:"client_id,omitempty"`
	LogLevel int32    `protobuf:"varint,2,opt,name=log_level,json=logLevel" json:"log_level,omitempty"`
	Message  []string `protobuf:"bytes,3,rep,name=message" json:"message,omitempty"`
}

Log Message

func (*LogMsg) Descriptor

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

func (*LogMsg) GetClientId

func (m *LogMsg) GetClientId() string

func (*LogMsg) GetLogLevel

func (m *LogMsg) GetLogLevel() int32

func (*LogMsg) GetMessage

func (m *LogMsg) GetMessage() []string

func (*LogMsg) ProtoMessage

func (*LogMsg) ProtoMessage()

func (*LogMsg) Reset

func (m *LogMsg) Reset()

func (*LogMsg) String

func (m *LogMsg) String() string

type LogPostClient

type LogPostClient interface {
	GetHeartBeat(ctx context.Context, in *EmptyMessage, opts ...grpc.CallOption) (*EmptyMessage, error)
	Register(ctx context.Context, in *EpInfo, opts ...grpc.CallOption) (*ConfigResp, error)
	LogReq(ctx context.Context, in *LogMsg, opts ...grpc.CallOption) (*EmptyMessage, error)
}

func NewLogPostClient

func NewLogPostClient(cc *grpc.ClientConn) LogPostClient

type LogPostServer

type LogPostServer interface {
	GetHeartBeat(context.Context, *EmptyMessage) (*EmptyMessage, error)
	Register(context.Context, *EpInfo) (*ConfigResp, error)
	LogReq(context.Context, *LogMsg) (*EmptyMessage, error)
}

Jump to

Keyboard shortcuts

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