Documentation
¶
Index ¶
- type MqueueStore
- func (s *MqueueStore) GetMqueueMux(ctx context.Context, mqueueID string, _ func()) (srpc.Invoker, func(), error)
- func (s *MqueueStore) ListMqueues(ctx context.Context, req *mqueue_rpc.ListMqueuesRequest) (*mqueue_rpc.ListMqueuesResponse, error)
- func (s *MqueueStore) MqueueRpc(strm mqueue_rpc.SRPCMqueueStore_MqueueRpcStream) error
- func (s *MqueueStore) RmMqueue(ctx context.Context, req *mqueue_rpc.RmMqueueRequest) (*mqueue_rpc.RmMqueueResponse, error)
- type Queue
- func (q *Queue) Ack(ctx context.Context, req *mqueue_rpc.AckRequest) (*mqueue_rpc.AckResponse, error)
- func (q *Queue) DeleteQueue(ctx context.Context, req *mqueue_rpc.DeleteQueueRequest) (*mqueue_rpc.DeleteQueueResponse, error)
- func (q *Queue) Peek(ctx context.Context, req *mqueue_rpc.PeekRequest) (*mqueue_rpc.PeekResponse, error)
- func (q *Queue) Push(ctx context.Context, req *mqueue_rpc.PushRequest) (*mqueue_rpc.PushResponse, error)
- func (q *Queue) Wait(ctx context.Context, req *mqueue_rpc.WaitRequest) (*mqueue_rpc.WaitResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MqueueStore ¶
type MqueueStore struct {
// contains filtered or unexported fields
}
MqueueStore implements the server with a MqueueStore.
func NewMqueueStore ¶
func NewMqueueStore(store mqueue_store.Store) *MqueueStore
NewMqueueStore constructs a new MqueueStore.
func (*MqueueStore) GetMqueueMux ¶
func (s *MqueueStore) GetMqueueMux(ctx context.Context, mqueueID string, _ func()) (srpc.Invoker, func(), error)
GetMqueueMux returns the srpc.Mux for a message queue.
func (*MqueueStore) ListMqueues ¶
func (s *MqueueStore) ListMqueues(ctx context.Context, req *mqueue_rpc.ListMqueuesRequest) (*mqueue_rpc.ListMqueuesResponse, error)
ListMqueues lists the message queues in the store.
func (*MqueueStore) MqueueRpc ¶
func (s *MqueueStore) MqueueRpc( strm mqueue_rpc.SRPCMqueueStore_MqueueRpcStream, ) error
MqueueRpc opens a RpcStream for a Queue.
func (*MqueueStore) RmMqueue ¶
func (s *MqueueStore) RmMqueue(ctx context.Context, req *mqueue_rpc.RmMqueueRequest) (*mqueue_rpc.RmMqueueResponse, error)
RmMqueue attempts to remove a message queue.
type Queue ¶
type Queue struct {
// contains filtered or unexported fields
}
Queue implements the message queue.
func (*Queue) Ack ¶
func (q *Queue) Ack(ctx context.Context, req *mqueue_rpc.AckRequest) (*mqueue_rpc.AckResponse, error)
Ack acknowledges a message by ID if the ID is the current message at the front of the queue.
func (*Queue) DeleteQueue ¶
func (q *Queue) DeleteQueue(ctx context.Context, req *mqueue_rpc.DeleteQueueRequest) (*mqueue_rpc.DeleteQueueResponse, error)
DeleteQueue deletes a queue and its contents.
func (*Queue) Peek ¶
func (q *Queue) Peek(ctx context.Context, req *mqueue_rpc.PeekRequest) (*mqueue_rpc.PeekResponse, error)
Peek peeks the next value in the queue without removing it.
func (*Queue) Push ¶
func (q *Queue) Push(ctx context.Context, req *mqueue_rpc.PushRequest) (*mqueue_rpc.PushResponse, error)
Push pushes a message to the queue.
func (*Queue) Wait ¶
func (q *Queue) Wait(ctx context.Context, req *mqueue_rpc.WaitRequest) (*mqueue_rpc.WaitResponse, error)
Wait waits for a message to arrive.
Click to show internal directories.
Click to hide internal directories.