Handle for sending queue messages via a bidirectional upstream stream.
Obtained via KubeMQ.Client.queue_upstream/1. Each send/2 call writes
a batch of messages and awaits the server response.
Usage
{:ok, handle} = KubeMQ.Client.queue_upstream(client)
{:ok, results} = KubeMQ.QueueUpstreamHandle.send(handle, [msg1, msg2])
:ok = KubeMQ.QueueUpstreamHandle.close(handle)
Summary
Functions
Returns a specification to start this module under a supervisor.
Close the queue upstream handle, terminating the underlying gRPC stream.
Send a batch of queue messages through the upstream streaming handle.
Types
@type t() :: GenServer.server()
Functions
Returns a specification to start this module under a supervisor.
See Supervisor.
@spec close(t()) :: :ok
Close the queue upstream handle, terminating the underlying gRPC stream.
@spec send(t(), [KubeMQ.QueueMessage.t()]) :: {:ok, [KubeMQ.QueueSendResult.t()]} | {:error, KubeMQ.Error.t()}
Send a batch of queue messages through the upstream streaming handle.
Writes messages to the underlying bidirectional gRPC stream and awaits per-message send results from the server.
@spec start_link(keyword()) :: GenServer.on_start()