Documentation ¶
Overview ¶
Package pb is a generated protocol buffer package.
It is generated from these files:
vinna.proto
It has these top-level messages:
Topic TopicCreated Message Success MessageRequest ProducerSummary ConsumeRequest
Index ¶
- func RegisterVinnaServer(s *grpc.Server, srv VinnaServer)
- type ConsumeRequest
- type Message
- type MessageRequest
- type ProducerSummary
- func (*ProducerSummary) Descriptor() ([]byte, []int)
- func (m *ProducerSummary) GetElapsedTime() int32
- func (m *ProducerSummary) GetMsgCount() int32
- func (m *ProducerSummary) GetTopicCount() int32
- func (*ProducerSummary) ProtoMessage()
- func (m *ProducerSummary) Reset()
- func (m *ProducerSummary) String() string
- type Success
- type Topic
- type TopicCreated
- type VinnaClient
- type VinnaServer
- type Vinna_ConsumeClient
- type Vinna_ConsumeServer
- type Vinna_ProduceClient
- type Vinna_ProduceServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterVinnaServer ¶
func RegisterVinnaServer(s *grpc.Server, srv VinnaServer)
Types ¶
type ConsumeRequest ¶
type ConsumeRequest struct {
Topic string `protobuf:"bytes,1,opt,name=topic" json:"topic,omitempty"`
}
func (*ConsumeRequest) Descriptor ¶
func (*ConsumeRequest) Descriptor() ([]byte, []int)
func (*ConsumeRequest) GetTopic ¶
func (m *ConsumeRequest) GetTopic() string
func (*ConsumeRequest) ProtoMessage ¶
func (*ConsumeRequest) ProtoMessage()
func (*ConsumeRequest) Reset ¶
func (m *ConsumeRequest) Reset()
func (*ConsumeRequest) String ¶
func (m *ConsumeRequest) String() string
type Message ¶
type Message struct { Uuid string `protobuf:"bytes,1,opt,name=uuid" json:"uuid,omitempty"` Topic string `protobuf:"bytes,2,opt,name=topic" json:"topic,omitempty"` Msg []byte `protobuf:"bytes,3,opt,name=msg,proto3" json:"msg,omitempty"` }
func (*Message) Descriptor ¶
func (*Message) ProtoMessage ¶
func (*Message) ProtoMessage()
type MessageRequest ¶
type MessageRequest struct { Topic string `protobuf:"bytes,1,opt,name=topic" json:"topic,omitempty"` MsgID string `protobuf:"bytes,2,opt,name=msgID" json:"msgID,omitempty"` }
func (*MessageRequest) Descriptor ¶
func (*MessageRequest) Descriptor() ([]byte, []int)
func (*MessageRequest) GetMsgID ¶
func (m *MessageRequest) GetMsgID() string
func (*MessageRequest) GetTopic ¶
func (m *MessageRequest) GetTopic() string
func (*MessageRequest) ProtoMessage ¶
func (*MessageRequest) ProtoMessage()
func (*MessageRequest) Reset ¶
func (m *MessageRequest) Reset()
func (*MessageRequest) String ¶
func (m *MessageRequest) String() string
type ProducerSummary ¶
type ProducerSummary struct { MsgCount int32 `protobuf:"varint,1,opt,name=msgCount" json:"msgCount,omitempty"` TopicCount int32 `protobuf:"varint,2,opt,name=topicCount" json:"topicCount,omitempty"` ElapsedTime int32 `protobuf:"varint,3,opt,name=elapsedTime" json:"elapsedTime,omitempty"` }
func (*ProducerSummary) Descriptor ¶
func (*ProducerSummary) Descriptor() ([]byte, []int)
func (*ProducerSummary) GetElapsedTime ¶
func (m *ProducerSummary) GetElapsedTime() int32
func (*ProducerSummary) GetMsgCount ¶
func (m *ProducerSummary) GetMsgCount() int32
func (*ProducerSummary) GetTopicCount ¶
func (m *ProducerSummary) GetTopicCount() int32
func (*ProducerSummary) ProtoMessage ¶
func (*ProducerSummary) ProtoMessage()
func (*ProducerSummary) Reset ¶
func (m *ProducerSummary) Reset()
func (*ProducerSummary) String ¶
func (m *ProducerSummary) String() string
type Success ¶
type Success struct { MsgID string `protobuf:"bytes,1,opt,name=msgID" json:"msgID,omitempty"` Success bool `protobuf:"varint,2,opt,name=success" json:"success,omitempty"` }
func (*Success) Descriptor ¶
func (*Success) GetSuccess ¶
func (*Success) ProtoMessage ¶
func (*Success) ProtoMessage()
type Topic ¶
type Topic struct {
Topic string `protobuf:"bytes,1,opt,name=topic" json:"topic,omitempty"`
}
func (*Topic) Descriptor ¶
func (*Topic) ProtoMessage ¶
func (*Topic) ProtoMessage()
type TopicCreated ¶
type TopicCreated struct {
Success bool `protobuf:"varint,1,opt,name=success" json:"success,omitempty"`
}
func (*TopicCreated) Descriptor ¶
func (*TopicCreated) Descriptor() ([]byte, []int)
func (*TopicCreated) GetSuccess ¶
func (m *TopicCreated) GetSuccess() bool
func (*TopicCreated) ProtoMessage ¶
func (*TopicCreated) ProtoMessage()
func (*TopicCreated) Reset ¶
func (m *TopicCreated) Reset()
func (*TopicCreated) String ¶
func (m *TopicCreated) String() string
type VinnaClient ¶
type VinnaClient interface { // NewTopic will create a new topic for messages NewTopic(ctx context.Context, in *Topic, opts ...grpc.CallOption) (*TopicCreated, error) // Add a message to vinna Add(ctx context.Context, in *Message, opts ...grpc.CallOption) (*Success, error) // Take a message from vinna Take(ctx context.Context, in *MessageRequest, opts ...grpc.CallOption) (*Message, error) // Produce will open up a production stream of data Produce(ctx context.Context, opts ...grpc.CallOption) (Vinna_ProduceClient, error) // Consumer will be an endpoint for streaming data to a client side consumer Consume(ctx context.Context, in *ConsumeRequest, opts ...grpc.CallOption) (Vinna_ConsumeClient, error) }
func NewVinnaClient ¶
func NewVinnaClient(cc *grpc.ClientConn) VinnaClient
type VinnaServer ¶
type VinnaServer interface { // NewTopic will create a new topic for messages NewTopic(context.Context, *Topic) (*TopicCreated, error) // Add a message to vinna Add(context.Context, *Message) (*Success, error) // Take a message from vinna Take(context.Context, *MessageRequest) (*Message, error) // Produce will open up a production stream of data Produce(Vinna_ProduceServer) error // Consumer will be an endpoint for streaming data to a client side consumer Consume(*ConsumeRequest, Vinna_ConsumeServer) error }
type Vinna_ConsumeClient ¶
type Vinna_ConsumeClient interface { Recv() (*Message, error) grpc.ClientStream }
type Vinna_ConsumeServer ¶
type Vinna_ConsumeServer interface { Send(*Message) error grpc.ServerStream }
type Vinna_ProduceClient ¶
type Vinna_ProduceClient interface { Send(*Message) error CloseAndRecv() (*ProducerSummary, error) grpc.ClientStream }
type Vinna_ProduceServer ¶
type Vinna_ProduceServer interface { SendAndClose(*ProducerSummary) error Recv() (*Message, error) grpc.ServerStream }
Click to show internal directories.
Click to hide internal directories.