Show / Hide Table of Contents

Class Metric

The properties that define a metric. For information about metrics, see Metrics Overview.

Inheritance
object
Metric
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Oci.MonitoringService.Models
Assembly: OCI.DotNetSDK.Monitoring.dll
Syntax
public class Metric

Properties

CompartmentId

Declaration
[JsonProperty(PropertyName = "compartmentId")]
public string CompartmentId { get; set; }
Property Value
Type Description
string

The OCID of the compartment containing the resources monitored by the metric.

Dimensions

Declaration
[JsonProperty(PropertyName = "dimensions")]
public Dictionary<string, string> Dimensions { get; set; }
Property Value
Type Description
Dictionary<string, string>

Qualifiers provided in a metric definition. Available dimensions vary by metric namespace. Each dimension takes the form of a key-value pair.
Example: {"resourceId": "ocid1.instance.region1.phx.exampleuniqueID"}

Name

Declaration
[JsonProperty(PropertyName = "name")]
public string Name { get; set; }
Property Value
Type Description
string

The name of the metric.
Example: CpuUtilization

Namespace

Declaration
[JsonProperty(PropertyName = "namespace")]
public string Namespace { get; set; }
Property Value
Type Description
string

The source service or application emitting the metric.
Example: oci_computeagent

ResourceGroup

Declaration
[JsonProperty(PropertyName = "resourceGroup")]
public string ResourceGroup { get; set; }
Property Value
Type Description
string

Resource group provided with the posted metric. A resource group is a custom string that you can match when retrieving custom metrics. Only one resource group can be applied per metric. A valid resourceGroup value starts with an alphabetical character and includes only alphanumeric characters, periods (.), underscores (_), hyphens (-), and dollar signs ($).
Example: frontend-fleet

In this article
Back to top