Files
zeekay df7d6cb470 feat: rebrand signoz-otel-collector → Hanzo OTEL Collector
- Go module: github.com/SigNoz/signoz-otel-collector → github.com/hanzoai/otel-collector
- All signoz-prefixed packages → o11y-prefixed
- Docker: signoz/* → ghcr.io/hanzoai/otel-collector
- ClickHouse exporter → Hanzo Datastore
- Env vars: SIGNOZ_* → HANZO_*
- Directory renames for all processor/receiver/exporter packages
2026-03-12 00:21:24 -07:00

48 lines
1.8 KiB
Go

// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
package cwmetricstream // import "github.com/hanzoai/otel-collector/receiver/o11yawsfirehosereceiver/internal/unmarshaler/cwmetricstream"
// The cWMetric is the format for the CloudWatch metric stream records.
//
// More details can be found at:
// https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-metric-streams-formats-json.html
type cWMetric struct {
// MetricStreamName is the name of the CloudWatch metric stream.
MetricStreamName string `json:"metric_stream_name"`
// AccountID is the AWS account ID associated with the metric.
AccountID string `json:"account_id"`
// Region is the AWS region for the metric.
Region string `json:"region"`
// Namespace is the CloudWatch namespace the metric is in.
Namespace string `json:"namespace"`
// MetricName is the name of the metric.
MetricName string `json:"metric_name"`
// Dimensions is a map of name/value pairs that help to
// differentiate a metric.
Dimensions map[string]string `json:"dimensions"`
// Timestamp is the milliseconds since epoch for
// the metric.
Timestamp int64 `json:"timestamp"`
// Value is the cWMetricValue, which has the min, max,
// sum, and count.
Value *cWMetricValue `json:"value"`
// Unit is the unit for the metric.
//
// More details can be found at:
// https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_MetricDatum.html
Unit string `json:"unit"`
}
// The cWMetricValue is the actual values of the CloudWatch metric.
type cWMetricValue struct {
// Max is the highest value observed.
Max float64 `json:"max"`
// Min is the lowest value observed.
Min float64 `json:"min"`
// Sum is the sum of data points collected.
Sum float64 `json:"sum"`
// Count is the number of data points.
Count float64 `json:"count"`
}