metrics

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2020 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const Subsystem = "appmesh"

Subsystem represents the Prometheus metrics prefix

Variables

This section is empty.

Functions

This section is empty.

Types

type Recorder

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

Recorder exports mesh stats as Prometheus metrics

func NewRecorder

func NewRecorder(register bool) *Recorder

NewRecorder registers the App Mesh metrics

func (*Recorder) RecordAWSAPIRequestCount added in v0.4.0

func (r *Recorder) RecordAWSAPIRequestCount(service string, operation string)

RecordAWSAPIRequestCount records count of AWS API call attempts

func (*Recorder) RecordAWSAPIRequestError added in v0.4.0

func (r *Recorder) RecordAWSAPIRequestError(service string, operation string, errorcode string)

RecordAWSAPIRequestError records error count of AWS API calls

func (*Recorder) RecordOperationDuration added in v0.4.0

func (r *Recorder) RecordOperationDuration(kind string, object string, operation string, duration time.Duration)

RecordOperationDuration records the duration of operation (e.g. API Call, Function exection) based on object kind, name and operation type. Operation can be any string based on the context, e.g. get, create

func (*Recorder) SetMeshActive

func (r *Recorder) SetMeshActive(name string)

SetMeshActive sets the mesh gauge to 1

func (*Recorder) SetMeshInactive

func (r *Recorder) SetMeshInactive(name string)

SetMeshActive sets the mesh gauge to 0 indicating that the object was deleted

func (*Recorder) SetRequestDuration

func (r *Recorder) SetRequestDuration(kind string, object string, operation string, duration time.Duration)

SetRequestDuration records the duration of App Mesh API calls based on object kind, name and operation type The operation type can be get, create, update, delete

func (*Recorder) SetVirtualNodeActive

func (r *Recorder) SetVirtualNodeActive(name string, mesh string)

SetVirtualNodeActive sets the virtual node gauge to 1

func (*Recorder) SetVirtualNodeInactive

func (r *Recorder) SetVirtualNodeInactive(name string, mesh string)

SetVirtualNodeInactive sets the mesh gauge to 0 indicating that the object was deleted

func (*Recorder) SetVirtualServiceActive

func (r *Recorder) SetVirtualServiceActive(name string, mesh string)

SetVirtualServiceActive sets the virtual service gauge to 1

func (*Recorder) SetVirtualServiceInactive

func (r *Recorder) SetVirtualServiceInactive(name string, mesh string)

SetVirtualServiceInactive sets the mesh gauge to 0 indicating that the object was deleted

Jump to

Keyboard shortcuts

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