Documentation ¶
Overview ¶
Package proximo provides proximo support for substrate
Usage ¶
This package support two methods of use. The first is to directly use this package. See the function documentation for more details.
The second method is to use the suburl package. See https://godoc.org/github.com/charlie/substrate/suburl for more information.
Using suburl ¶
The url structure is proximo://host:port/topic/
Additionally, for sources, the following url parameters are available
offset - The initial offset. Valid values are `newest` and `oldest`. consumer-group - The consumer group id keep-alive-time - The interval that a keep alive is performed at as a go duration keep-alive-timeout - The go duration at which a keepalive will timeout [Default: 10s] (requires keep-alive-time to take effect, if keep-alive-time is not present this is ignored) insecure=true - The connection to the proximo grpc endpoint will not be using TLS max-recv-msg-size - The gRPC max receive message size in bytes (source only) [Default: 67,108,864 (64MiB)]
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewAsyncMessageSink ¶
func NewAsyncMessageSink(c AsyncMessageSinkConfig) (substrate.AsyncMessageSink, error)
func NewAsyncMessageSource ¶
func NewAsyncMessageSource(c AsyncMessageSourceConfig) (substrate.AsyncMessageSource, error)
Types ¶
type AsyncMessageSinkConfig ¶
type AsyncMessageSourceConfig ¶
type AsyncMessageSourceConfig struct { ConsumerGroup string Topic string Broker string Offset Offset Insecure bool KeepAlive *KeepAlive MaxRecvMsgSize int }
AsyncMessageSource represents a proximo message source and implements the substrate.AsyncMessageSource interface.
type KeepAlive ¶
type KeepAlive struct { // Time the interval at which a keep alive is performed Time time.Duration // TimeOut the duration in which a keep alive is deemed to have failed if no response is received Timeout time.Duration }
KeepAlive provides configuration for the gRPC keep alive
Click to show internal directories.
Click to hide internal directories.