package metric_agent

import (
	"strconv"

	"github.com/tidbcloud/aws-shared-provider/pkg/o11y"
	infraconsts "github.com/tidbcloud/infra-api/pkg/consts"
	infra "github.com/tidbcloud/tidb-management-service/api/serverless_infra"
)

const (
	AWSFreeTier = "aws"
	AliCloud    = "alicloud"
)

func AddClusterRemoteWriteToClusterAnn(c *infra.Cluster, remoteWrite, o11yID string, o11yVersion int) {
	if c.Annotations == nil {
		c.Annotations = make(map[string]string)
	}
	c.Annotations[o11y.O11yClusterRemoteWriteAnnotationKey] = remoteWrite
	c.Annotations[infraconsts.O11yIDAnnotationKey] = o11yID
	c.Annotations[infraconsts.O11yVersionAnnotationKey] = strconv.Itoa(o11yVersion)
}
