Documentation

Overview

The metricsmanager package contains implementation for an api facade to access metrics functions within state

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client provides access to the metrics manager api

func NewClient

func NewClient(apiCaller base.APICaller) (*Client, error)

NewClient creates a new client for accessing the metricsmanager api

func (*Client) CleanupOldMetrics

func (c *Client) CleanupOldMetrics() error

CleanupOldMetrics looks for metrics that are 24 hours old (or older) and have been sent. Any metrics it finds are deleted.

func (*Client) SendMetrics

func (c *Client) SendMetrics() error

SendMetrics will send any unsent metrics to the collection service.

type MetricsManagerClient

type MetricsManagerClient interface {
	CleanupOldMetrics() error
	SendMetrics() error
}

MetricsManagerClient defines the methods on the metricsmanager API end point.

Source Files