Documentation ¶
Index ¶
- Variables
- func NewAlertEndpoints() []*api.Endpoint
- func RegisterAlertHandler(s server.Server, hdlr AlertHandler, opts ...server.HandlerOption) error
- func RegisterAlertServer(s *grpc.Server, srv AlertServer)
- type AlertClient
- type AlertHandler
- type AlertServer
- type AlertService
- type Event
- func (*Event) Descriptor() ([]byte, []int)deprecated
- func (x *Event) GetAction() string
- func (x *Event) GetCategory() string
- func (x *Event) GetId() string
- func (x *Event) GetLabel() string
- func (x *Event) GetMetadata() map[string]string
- func (x *Event) GetValue() uint64
- func (*Event) ProtoMessage()
- func (x *Event) ProtoReflect() protoreflect.Message
- func (x *Event) Reset()
- func (x *Event) String() string
- type ReportEventRequest
- func (*ReportEventRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ReportEventRequest) GetEvent() *Event
- func (*ReportEventRequest) ProtoMessage()
- func (x *ReportEventRequest) ProtoReflect() protoreflect.Message
- func (x *ReportEventRequest) Reset()
- func (x *ReportEventRequest) String() string
- type ReportEventResponse
- type UnimplementedAlertServer
Constants ¶
This section is empty.
Variables ¶
View Source
var File_proto_alert_alert_proto protoreflect.FileDescriptor
Functions ¶
func NewAlertEndpoints ¶
func RegisterAlertHandler ¶
func RegisterAlertHandler(s server.Server, hdlr AlertHandler, opts ...server.HandlerOption) error
func RegisterAlertServer ¶ added in v3.8.3
func RegisterAlertServer(s *grpc.Server, srv AlertServer)
Types ¶
type AlertClient ¶ added in v3.8.3
type AlertClient interface { // ReportEvent does event ingestions. ReportEvent(ctx context.Context, in *ReportEventRequest, opts ...grpc.CallOption) (*ReportEventResponse, error) }
AlertClient is the client API for Alert service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewAlertClient ¶ added in v3.8.3
func NewAlertClient(cc grpc.ClientConnInterface) AlertClient
type AlertHandler ¶
type AlertHandler interface { // ReportEvent does event ingestions. ReportEvent(context.Context, *ReportEventRequest, *ReportEventResponse) error }
type AlertServer ¶ added in v3.8.3
type AlertServer interface { // ReportEvent does event ingestions. ReportEvent(context.Context, *ReportEventRequest) (*ReportEventResponse, error) }
AlertServer is the server API for Alert service.
type AlertService ¶
type AlertService interface { // ReportEvent does event ingestions. ReportEvent(ctx context.Context, in *ReportEventRequest, opts ...client.CallOption) (*ReportEventResponse, error) }
func NewAlertService ¶
func NewAlertService(name string, c client.Client) AlertService
type Event ¶
type Event struct { // id is not required for inserts Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Category string `protobuf:"bytes,2,opt,name=category,proto3" json:"category,omitempty"` Action string `protobuf:"bytes,3,opt,name=action,proto3" json:"action,omitempty"` Label string `protobuf:"bytes,4,opt,name=label,proto3" json:"label,omitempty"` Value uint64 `protobuf:"varint,5,opt,name=value,proto3" json:"value,omitempty"` Metadata map[string]string `` /* 157-byte string literal not displayed */ // contains filtered or unexported fields }
Event is inspired by Google Analytics events https://developers.google.com/analytics/devguides/collection/analyticsjs/events
func (*Event) Descriptor
deprecated
func (*Event) GetCategory ¶
func (*Event) GetMetadata ¶
func (*Event) ProtoMessage ¶
func (*Event) ProtoMessage()
func (*Event) ProtoReflect ¶
func (x *Event) ProtoReflect() protoreflect.Message
type ReportEventRequest ¶
type ReportEventRequest struct { Event *Event `protobuf:"bytes,1,opt,name=event,proto3" json:"event,omitempty"` // contains filtered or unexported fields }
func (*ReportEventRequest) Descriptor
deprecated
func (*ReportEventRequest) Descriptor() ([]byte, []int)
Deprecated: Use ReportEventRequest.ProtoReflect.Descriptor instead.
func (*ReportEventRequest) GetEvent ¶
func (x *ReportEventRequest) GetEvent() *Event
func (*ReportEventRequest) ProtoMessage ¶
func (*ReportEventRequest) ProtoMessage()
func (*ReportEventRequest) ProtoReflect ¶
func (x *ReportEventRequest) ProtoReflect() protoreflect.Message
func (*ReportEventRequest) Reset ¶
func (x *ReportEventRequest) Reset()
func (*ReportEventRequest) String ¶
func (x *ReportEventRequest) String() string
type ReportEventResponse ¶
type ReportEventResponse struct {
// contains filtered or unexported fields
}
func (*ReportEventResponse) Descriptor
deprecated
func (*ReportEventResponse) Descriptor() ([]byte, []int)
Deprecated: Use ReportEventResponse.ProtoReflect.Descriptor instead.
func (*ReportEventResponse) ProtoMessage ¶
func (*ReportEventResponse) ProtoMessage()
func (*ReportEventResponse) ProtoReflect ¶
func (x *ReportEventResponse) ProtoReflect() protoreflect.Message
func (*ReportEventResponse) Reset ¶
func (x *ReportEventResponse) Reset()
func (*ReportEventResponse) String ¶
func (x *ReportEventResponse) String() string
type UnimplementedAlertServer ¶ added in v3.8.3
type UnimplementedAlertServer struct { }
UnimplementedAlertServer can be embedded to have forward compatible implementations.
func (*UnimplementedAlertServer) ReportEvent ¶ added in v3.8.3
func (*UnimplementedAlertServer) ReportEvent(context.Context, *ReportEventRequest) (*ReportEventResponse, error)
Click to show internal directories.
Click to hide internal directories.