pubsub

package
v0.14.1-0...-915d78e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 21, 2020 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	Project             string `toml:"project"`
	Subscription        string `toml:"subscription"`
	ReceiverGoRoutines  int    `toml:"receiver_go_routines"`
	ReceiverMaxMessages int    `toml:"receiver_max_messages"`
	ReceiverMaxBytes    int    `toml:"receiver_max_bytes"`
}

Options contains all receiver's options that can be changed by user

func NewOptions

func NewOptions() *Options

NewOptions returns Options struct filled with default values.

type PubSub

type PubSub struct {
	// contains filtered or unexported fields
}

PubSub receive metrics from a google pubsub subscription

func (*PubSub) InitPrometheus

func (rcv *PubSub) InitPrometheus(reg prometheus.Registerer)

InitPrometheus is a stub for the receiver prom metrics. Required to satisfy Receiver interface.

func (*PubSub) Stat

func (rcv *PubSub) Stat(send helper.StatCallback)

Stat sends pubsub receiver's internal stats to specified callback

func (*PubSub) Stop

func (rcv *PubSub) Stop()

Stop shuts down the pubsub receiver and waits until all message processing is completed before returning

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL