Documentation ¶
Index ¶
Constants ¶
View Source
const ( // LBProvision is the OCI metric suffix for LB provision LBProvision = "LB_PROVISION" // LBUpdate is the OCI metric suffix for LB update LBUpdate = "LB_UPDATE" // LBDelete is the OCI metric suffix for LB delete LBDelete = "LB_DELETE" // PVProvision is the OCI metric suffix for PV provision PVProvision = "PV_PROVISION" // PVAttach is the OCI metric suffix for PV attach PVAttach = "PV_ATTACH" // PVDetach is the OCI metric suffix for PV detach PVDetach = "PV_DETACH" // PVDelete is the OCI metric suffix for PV delete PVDelete = "PV_DELETE" // PVProvision is the OCI metric suffix for PV provision PVExpand = "PV_EXPAND" ResourceOCIDDimension = "resourceOCID" ComponentDimension = "component" BackendSetsCountDimension = "backendSetsCount" )
Variables ¶
This section is empty.
Functions ¶
func SendMetricData ¶
func SendMetricData(metricPusher *MetricPusher, metric string, value float64, dimensionsMap map[string]string)
SendMetricData is used to send the metric
Types ¶
type MetricPusher ¶
type MetricPusher struct {
// contains filtered or unexported fields
}
MetricPusher is the wrapper used to push metrics to OCI monitoring service.
func NewMetricPusher ¶
func NewMetricPusher(logger *zap.SugaredLogger) (*MetricPusher, error)
NewMetricPusher creates a new OCI Metric pusher
type MonitoringClient ¶
type MonitoringClient interface {
PostMetricData(ctx context.Context, request monitoring.PostMetricDataRequest) (response monitoring.PostMetricDataResponse, err error)
}
MonitoringClient is wrapper interface over the oci golang monitoring client
Click to show internal directories.
Click to hide internal directories.