Documentation ¶
Index ¶
- Variables
- func Setup(conf *config.Config, updateInterval time.Duration, logger *logrus.Logger) error
- func Shutdown()
- type Manager
- type Meta
- type MetaManager
- func (mm *MetaManager) Close()
- func (mm *MetaManager) Create(pool, ns, group string, meta *Meta) error
- func (mm *MetaManager) Delete(pool, ns, group string) error
- func (mm *MetaManager) Dump() map[string]map[string][]string
- func (mm *MetaManager) Get(pool, ns, group string) *Meta
- func (mm *MetaManager) GetFromRemote(pool, ns, group string) (*Meta, error)
- func (mm *MetaManager) ListPusherByNamespace(wantedPool, wantedNamespace string) map[string]Meta
- func (mm *MetaManager) Update(pool, ns, group string, meta *Meta) error
- type PerformanceMetrics
- type Pusher
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidKey = errors.New("invalid push meta key")
View Source
var ErrMetaKeyExists = errors.New("the meta key has already exists")
View Source
var ErrMetaKeyNotFound = errors.New("the meta key was not found")
Functions ¶
Types ¶
type Manager ¶
type Manager struct { *MetaManager // contains filtered or unexported fields }
func GetManager ¶
func GetManager() *Manager
func (*Manager) SetCallbacks ¶
func (m *Manager) SetCallbacks(onCreated onCreatedFunc, onUpdated onUpdatedFunc, onDeleted onDeletedFunc)
SetCallbacks used to set custom callback when meta was changed. e.g. we want to use empty callback function to fasten test cases
type Meta ¶
type MetaManager ¶
type MetaManager struct {
// contains filtered or unexported fields
}
func (*MetaManager) Close ¶
func (mm *MetaManager) Close()
func (*MetaManager) Create ¶
func (mm *MetaManager) Create(pool, ns, group string, meta *Meta) error
func (*MetaManager) Delete ¶
func (mm *MetaManager) Delete(pool, ns, group string) error
func (*MetaManager) Get ¶
func (mm *MetaManager) Get(pool, ns, group string) *Meta
func (*MetaManager) GetFromRemote ¶
func (mm *MetaManager) GetFromRemote(pool, ns, group string) (*Meta, error)
func (*MetaManager) ListPusherByNamespace ¶
func (mm *MetaManager) ListPusherByNamespace(wantedPool, wantedNamespace string) map[string]Meta
type PerformanceMetrics ¶
type PerformanceMetrics struct { ConsumeLatencies *prometheus.HistogramVec PushLatencies *prometheus.HistogramVec PushHTTPCodes *prometheus.CounterVec }
Click to show internal directories.
Click to hide internal directories.