emf

package
v1.26.1 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2024 License: Apache-2.0 Imports: 3 Imported by: 1

Documentation

Overview

Package emf implements an EMF metrics publisher.

This package is designated as private and is intended for use only by the smithy client runtime. The exported API therein is not considered stable and is subject to breaking changes without notice.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Entry

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

Entry represents a log entry in the EMF format.

func NewEntry

func NewEntry(namespace string, serializer metrics.Serializer) Entry

NewEntry creates a new Entry with the specified namespace and serializer.

func (*Entry) AddDimension

func (e *Entry) AddDimension(key string, value string)

AddDimension adds a CW Dimension to the EMF entry.

func (*Entry) AddMetric

func (e *Entry) AddMetric(key string, value float64)

AddMetric adds a CW Metric to the EMF entry.

func (*Entry) AddProperty

func (e *Entry) AddProperty(key string, value interface{})

AddProperty adds a CW Property to the EMF entry. Properties are not published as metrics, but they are available in logs and in CW insights.

func (*Entry) Build

func (e *Entry) Build() (string, error)

Build constructs the EMF log entry as a JSON string.

Jump to

Keyboard shortcuts

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