api

package
v0.14.0 Latest Latest
Warning

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

Go to latest
Published: May 17, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Api

type Api struct {
	stop.Struct
	// contains filtered or unexported fields
}

Api receive metrics from GRPC connections

func New

func New(c *cache.Cache) *Api

func (*Api) Addr

func (api *Api) Addr() net.Addr

Addr returns binded socket address. For bind port 0 in tests

func (*Api) CacheQuery

func (api *Api) CacheQuery(ctx context.Context, req *carbonpb.CacheRequest) (*carbonpb.Payload, error)

func (*Api) Listen

func (api *Api) Listen(addr *net.TCPAddr) error

Listen bind port. Receive messages and send to out channel

func (*Api) Stat

func (api *Api) Stat(send helper.StatCallback)

Collect cache metrics

Directories

Path Synopsis
sample

Jump to

Keyboard shortcuts

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