Documentation ¶
Index ¶
- Variables
- func NewStoreEndpoints() []*api.Endpoint
- func NewStreamEndpoints() []*api.Endpoint
- func RegisterStoreHandler(s server.Server, hdlr StoreHandler, opts ...server.HandlerOption) error
- func RegisterStoreServer(s *grpc.Server, srv StoreServer)
- func RegisterStreamHandler(s server.Server, hdlr StreamHandler, opts ...server.HandlerOption) error
- func RegisterStreamServer(s *grpc.Server, srv StreamServer)
- type AckRequest
- type ConsumeRequest
- func (*ConsumeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ConsumeRequest) GetAckWait() int64
- func (x *ConsumeRequest) GetAutoAck() bool
- func (x *ConsumeRequest) GetGroup() string
- func (x *ConsumeRequest) GetOffset() int64
- func (x *ConsumeRequest) GetRetryLimit() int64
- func (x *ConsumeRequest) GetTopic() string
- func (*ConsumeRequest) ProtoMessage()
- func (x *ConsumeRequest) ProtoReflect() protoreflect.Message
- func (x *ConsumeRequest) Reset()
- func (x *ConsumeRequest) String() string
- type Event
- func (*Event) Descriptor() ([]byte, []int)deprecated
- func (x *Event) GetId() string
- func (x *Event) GetMetadata() map[string]string
- func (x *Event) GetPayload() []byte
- func (x *Event) GetTimestamp() int64
- func (x *Event) GetTopic() string
- func (*Event) ProtoMessage()
- func (x *Event) ProtoReflect() protoreflect.Message
- func (x *Event) Reset()
- func (x *Event) String() string
- type PublishRequest
- func (*PublishRequest) Descriptor() ([]byte, []int)deprecated
- func (x *PublishRequest) GetMetadata() map[string]string
- func (x *PublishRequest) GetPayload() []byte
- func (x *PublishRequest) GetTimestamp() int64
- func (x *PublishRequest) GetTopic() string
- func (*PublishRequest) ProtoMessage()
- func (x *PublishRequest) ProtoReflect() protoreflect.Message
- func (x *PublishRequest) Reset()
- func (x *PublishRequest) String() string
- type PublishResponse
- type ReadRequest
- func (*ReadRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ReadRequest) GetLimit() uint64
- func (x *ReadRequest) GetOffset() uint64
- func (x *ReadRequest) GetTopic() string
- func (*ReadRequest) ProtoMessage()
- func (x *ReadRequest) ProtoReflect() protoreflect.Message
- func (x *ReadRequest) Reset()
- func (x *ReadRequest) String() string
- type ReadResponse
- type StoreClient
- type StoreHandler
- type StoreServer
- type StoreService
- type StreamClient
- type StreamHandler
- type StreamServer
- type StreamService
- type Stream_ConsumeClient
- type Stream_ConsumeServer
- type Stream_ConsumeService
- type Stream_ConsumeStream
- type UnimplementedStoreServer
- type UnimplementedStreamServer
- type WriteRequest
- func (*WriteRequest) Descriptor() ([]byte, []int)deprecated
- func (x *WriteRequest) GetEvent() *Event
- func (x *WriteRequest) GetTtl() int64
- func (*WriteRequest) ProtoMessage()
- func (x *WriteRequest) ProtoReflect() protoreflect.Message
- func (x *WriteRequest) Reset()
- func (x *WriteRequest) String() string
- type WriteResponse
Constants ¶
This section is empty.
Variables ¶
var File_proto_events_events_proto protoreflect.FileDescriptor
Functions ¶
func NewStoreEndpoints ¶
func NewStreamEndpoints ¶
func RegisterStoreHandler ¶
func RegisterStoreHandler(s server.Server, hdlr StoreHandler, opts ...server.HandlerOption) error
func RegisterStoreServer ¶
func RegisterStoreServer(s *grpc.Server, srv StoreServer)
func RegisterStreamHandler ¶
func RegisterStreamHandler(s server.Server, hdlr StreamHandler, opts ...server.HandlerOption) error
func RegisterStreamServer ¶
func RegisterStreamServer(s *grpc.Server, srv StreamServer)
Types ¶
type AckRequest ¶
type AckRequest struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Success bool `protobuf:"varint,2,opt,name=success,proto3" json:"success,omitempty"` // contains filtered or unexported fields }
func (*AckRequest) Descriptor
deprecated
func (*AckRequest) Descriptor() ([]byte, []int)
Deprecated: Use AckRequest.ProtoReflect.Descriptor instead.
func (*AckRequest) GetId ¶
func (x *AckRequest) GetId() string
func (*AckRequest) GetSuccess ¶
func (x *AckRequest) GetSuccess() bool
func (*AckRequest) ProtoMessage ¶
func (*AckRequest) ProtoMessage()
func (*AckRequest) ProtoReflect ¶ added in v3.8.3
func (x *AckRequest) ProtoReflect() protoreflect.Message
func (*AckRequest) Reset ¶
func (x *AckRequest) Reset()
func (*AckRequest) String ¶
func (x *AckRequest) String() string
type ConsumeRequest ¶
type ConsumeRequest struct { Group string `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"` Topic string `protobuf:"bytes,2,opt,name=topic,proto3" json:"topic,omitempty"` Offset int64 `protobuf:"varint,3,opt,name=offset,proto3" json:"offset,omitempty"` AutoAck bool `protobuf:"varint,4,opt,name=auto_ack,json=autoAck,proto3" json:"auto_ack,omitempty"` // duration in nanoseconds AckWait int64 `protobuf:"varint,5,opt,name=ack_wait,json=ackWait,proto3" json:"ack_wait,omitempty"` RetryLimit int64 `protobuf:"varint,6,opt,name=retry_limit,json=retryLimit,proto3" json:"retry_limit,omitempty"` // contains filtered or unexported fields }
func (*ConsumeRequest) Descriptor
deprecated
func (*ConsumeRequest) Descriptor() ([]byte, []int)
Deprecated: Use ConsumeRequest.ProtoReflect.Descriptor instead.
func (*ConsumeRequest) GetAckWait ¶
func (x *ConsumeRequest) GetAckWait() int64
func (*ConsumeRequest) GetAutoAck ¶
func (x *ConsumeRequest) GetAutoAck() bool
func (*ConsumeRequest) GetGroup ¶
func (x *ConsumeRequest) GetGroup() string
func (*ConsumeRequest) GetOffset ¶
func (x *ConsumeRequest) GetOffset() int64
func (*ConsumeRequest) GetRetryLimit ¶
func (x *ConsumeRequest) GetRetryLimit() int64
func (*ConsumeRequest) GetTopic ¶
func (x *ConsumeRequest) GetTopic() string
func (*ConsumeRequest) ProtoMessage ¶
func (*ConsumeRequest) ProtoMessage()
func (*ConsumeRequest) ProtoReflect ¶ added in v3.8.3
func (x *ConsumeRequest) ProtoReflect() protoreflect.Message
func (*ConsumeRequest) Reset ¶
func (x *ConsumeRequest) Reset()
func (*ConsumeRequest) String ¶
func (x *ConsumeRequest) String() string
type Event ¶
type Event struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Topic string `protobuf:"bytes,2,opt,name=topic,proto3" json:"topic,omitempty"` Metadata map[string]string `` /* 157-byte string literal not displayed */ Payload []byte `protobuf:"bytes,4,opt,name=payload,proto3" json:"payload,omitempty"` Timestamp int64 `protobuf:"varint,5,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // contains filtered or unexported fields }
func (*Event) Descriptor
deprecated
func (*Event) GetMetadata ¶
func (*Event) GetPayload ¶
func (*Event) GetTimestamp ¶
func (*Event) ProtoMessage ¶
func (*Event) ProtoMessage()
func (*Event) ProtoReflect ¶ added in v3.8.3
func (x *Event) ProtoReflect() protoreflect.Message
type PublishRequest ¶
type PublishRequest struct { Topic string `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"` Metadata map[string]string `` /* 157-byte string literal not displayed */ Payload []byte `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"` Timestamp int64 `protobuf:"varint,4,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // contains filtered or unexported fields }
func (*PublishRequest) Descriptor
deprecated
func (*PublishRequest) Descriptor() ([]byte, []int)
Deprecated: Use PublishRequest.ProtoReflect.Descriptor instead.
func (*PublishRequest) GetMetadata ¶
func (x *PublishRequest) GetMetadata() map[string]string
func (*PublishRequest) GetPayload ¶
func (x *PublishRequest) GetPayload() []byte
func (*PublishRequest) GetTimestamp ¶
func (x *PublishRequest) GetTimestamp() int64
func (*PublishRequest) GetTopic ¶
func (x *PublishRequest) GetTopic() string
func (*PublishRequest) ProtoMessage ¶
func (*PublishRequest) ProtoMessage()
func (*PublishRequest) ProtoReflect ¶ added in v3.8.3
func (x *PublishRequest) ProtoReflect() protoreflect.Message
func (*PublishRequest) Reset ¶
func (x *PublishRequest) Reset()
func (*PublishRequest) String ¶
func (x *PublishRequest) String() string
type PublishResponse ¶
type PublishResponse struct {
// contains filtered or unexported fields
}
func (*PublishResponse) Descriptor
deprecated
func (*PublishResponse) Descriptor() ([]byte, []int)
Deprecated: Use PublishResponse.ProtoReflect.Descriptor instead.
func (*PublishResponse) ProtoMessage ¶
func (*PublishResponse) ProtoMessage()
func (*PublishResponse) ProtoReflect ¶ added in v3.8.3
func (x *PublishResponse) ProtoReflect() protoreflect.Message
func (*PublishResponse) Reset ¶
func (x *PublishResponse) Reset()
func (*PublishResponse) String ¶
func (x *PublishResponse) String() string
type ReadRequest ¶
type ReadRequest struct { Topic string `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"` Limit uint64 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"` Offset uint64 `protobuf:"varint,3,opt,name=offset,proto3" json:"offset,omitempty"` // contains filtered or unexported fields }
func (*ReadRequest) Descriptor
deprecated
func (*ReadRequest) Descriptor() ([]byte, []int)
Deprecated: Use ReadRequest.ProtoReflect.Descriptor instead.
func (*ReadRequest) GetLimit ¶
func (x *ReadRequest) GetLimit() uint64
func (*ReadRequest) GetOffset ¶
func (x *ReadRequest) GetOffset() uint64
func (*ReadRequest) GetTopic ¶
func (x *ReadRequest) GetTopic() string
func (*ReadRequest) ProtoMessage ¶
func (*ReadRequest) ProtoMessage()
func (*ReadRequest) ProtoReflect ¶ added in v3.8.3
func (x *ReadRequest) ProtoReflect() protoreflect.Message
func (*ReadRequest) Reset ¶
func (x *ReadRequest) Reset()
func (*ReadRequest) String ¶
func (x *ReadRequest) String() string
type ReadResponse ¶
type ReadResponse struct { Events []*Event `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"` // contains filtered or unexported fields }
func (*ReadResponse) Descriptor
deprecated
func (*ReadResponse) Descriptor() ([]byte, []int)
Deprecated: Use ReadResponse.ProtoReflect.Descriptor instead.
func (*ReadResponse) GetEvents ¶
func (x *ReadResponse) GetEvents() []*Event
func (*ReadResponse) ProtoMessage ¶
func (*ReadResponse) ProtoMessage()
func (*ReadResponse) ProtoReflect ¶ added in v3.8.3
func (x *ReadResponse) ProtoReflect() protoreflect.Message
func (*ReadResponse) Reset ¶
func (x *ReadResponse) Reset()
func (*ReadResponse) String ¶
func (x *ReadResponse) String() string
type StoreClient ¶
type StoreClient interface { Read(ctx context.Context, in *ReadRequest, opts ...grpc.CallOption) (*ReadResponse, error) Write(ctx context.Context, in *WriteRequest, opts ...grpc.CallOption) (*WriteResponse, error) }
StoreClient is the client API for Store service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewStoreClient ¶
func NewStoreClient(cc grpc.ClientConnInterface) StoreClient
type StoreHandler ¶
type StoreHandler interface { Read(context.Context, *ReadRequest, *ReadResponse) error Write(context.Context, *WriteRequest, *WriteResponse) error }
type StoreServer ¶
type StoreServer interface { Read(context.Context, *ReadRequest) (*ReadResponse, error) Write(context.Context, *WriteRequest) (*WriteResponse, error) }
StoreServer is the server API for Store service.
type StoreService ¶
type StoreService interface { Read(ctx context.Context, in *ReadRequest, opts ...client.CallOption) (*ReadResponse, error) Write(ctx context.Context, in *WriteRequest, opts ...client.CallOption) (*WriteResponse, error) }
func NewStoreService ¶
func NewStoreService(name string, c client.Client) StoreService
type StreamClient ¶
type StreamClient interface { Publish(ctx context.Context, in *PublishRequest, opts ...grpc.CallOption) (*PublishResponse, error) Consume(ctx context.Context, in *ConsumeRequest, opts ...grpc.CallOption) (Stream_ConsumeClient, error) }
StreamClient is the client API for Stream service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewStreamClient ¶
func NewStreamClient(cc grpc.ClientConnInterface) StreamClient
type StreamHandler ¶
type StreamHandler interface { Publish(context.Context, *PublishRequest, *PublishResponse) error Consume(context.Context, *ConsumeRequest, Stream_ConsumeStream) error }
type StreamServer ¶
type StreamServer interface { Publish(context.Context, *PublishRequest) (*PublishResponse, error) Consume(*ConsumeRequest, Stream_ConsumeServer) error }
StreamServer is the server API for Stream service.
type StreamService ¶
type StreamService interface { Publish(ctx context.Context, in *PublishRequest, opts ...client.CallOption) (*PublishResponse, error) Consume(ctx context.Context, in *ConsumeRequest, opts ...client.CallOption) (Stream_ConsumeService, error) }
func NewStreamService ¶
func NewStreamService(name string, c client.Client) StreamService
type Stream_ConsumeClient ¶
type Stream_ConsumeClient interface { Recv() (*Event, error) grpc.ClientStream }
type Stream_ConsumeServer ¶
type Stream_ConsumeServer interface { Send(*Event) error grpc.ServerStream }
type Stream_ConsumeService ¶
type Stream_ConsumeStream ¶
type UnimplementedStoreServer ¶ added in v3.8.3
type UnimplementedStoreServer struct { }
UnimplementedStoreServer can be embedded to have forward compatible implementations.
func (*UnimplementedStoreServer) Read ¶ added in v3.8.3
func (*UnimplementedStoreServer) Read(context.Context, *ReadRequest) (*ReadResponse, error)
func (*UnimplementedStoreServer) Write ¶ added in v3.8.3
func (*UnimplementedStoreServer) Write(context.Context, *WriteRequest) (*WriteResponse, error)
type UnimplementedStreamServer ¶ added in v3.8.3
type UnimplementedStreamServer struct { }
UnimplementedStreamServer can be embedded to have forward compatible implementations.
func (*UnimplementedStreamServer) Consume ¶ added in v3.8.3
func (*UnimplementedStreamServer) Consume(*ConsumeRequest, Stream_ConsumeServer) error
func (*UnimplementedStreamServer) Publish ¶ added in v3.8.3
func (*UnimplementedStreamServer) Publish(context.Context, *PublishRequest) (*PublishResponse, error)
type WriteRequest ¶
type WriteRequest struct { Event *Event `protobuf:"bytes,1,opt,name=event,proto3" json:"event,omitempty"` Ttl int64 `protobuf:"varint,2,opt,name=ttl,proto3" json:"ttl,omitempty"` // contains filtered or unexported fields }
func (*WriteRequest) Descriptor
deprecated
func (*WriteRequest) Descriptor() ([]byte, []int)
Deprecated: Use WriteRequest.ProtoReflect.Descriptor instead.
func (*WriteRequest) GetEvent ¶
func (x *WriteRequest) GetEvent() *Event
func (*WriteRequest) GetTtl ¶
func (x *WriteRequest) GetTtl() int64
func (*WriteRequest) ProtoMessage ¶
func (*WriteRequest) ProtoMessage()
func (*WriteRequest) ProtoReflect ¶ added in v3.8.3
func (x *WriteRequest) ProtoReflect() protoreflect.Message
func (*WriteRequest) Reset ¶
func (x *WriteRequest) Reset()
func (*WriteRequest) String ¶
func (x *WriteRequest) String() string
type WriteResponse ¶
type WriteResponse struct {
// contains filtered or unexported fields
}
func (*WriteResponse) Descriptor
deprecated
func (*WriteResponse) Descriptor() ([]byte, []int)
Deprecated: Use WriteResponse.ProtoReflect.Descriptor instead.
func (*WriteResponse) ProtoMessage ¶
func (*WriteResponse) ProtoMessage()
func (*WriteResponse) ProtoReflect ¶ added in v3.8.3
func (x *WriteResponse) ProtoReflect() protoreflect.Message
func (*WriteResponse) Reset ¶
func (x *WriteResponse) Reset()
func (*WriteResponse) String ¶
func (x *WriteResponse) String() string