Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func UTF8StringFromBytes ¶
Checks whether the bytes passed are valid utf8 string bytes. If they are not returns a sanitised string version of the bytes with offending sequences replaced by the utf8 replacement/error rune and an error indicating the offending byte sequences and their position. Note: always returns a valid string regardless of error.
Types ¶
type Consumer ¶
type Consumer struct { Config *config.VentConfig Log *logger.Logger Closing bool DB *sqldb.SQLDB GRPCConnection *grpc.ClientConn // external events channel used for when vent is leveraged as a library EventsChannel chan types.EventData }
Consumer contains basic configuration for consumer to run
func NewConsumer ¶
func NewConsumer(cfg *config.VentConfig, log *logger.Logger, eventChannel chan types.EventData) *Consumer
NewConsumer constructs a new consumer configuration. The event channel will be passed a collection of rows generated from all of the events in a single block It will be closed by the consumer when it is finished
type Server ¶
type Server struct { Config *config.VentConfig Log *logger.Logger Consumer *Consumer // contains filtered or unexported fields }
Server exposes HTTP endpoints for the service
Click to show internal directories.
Click to hide internal directories.