Class ListMetricsDetails.Builder

    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • name

        public ListMetricsDetails.Builder name​(String name)
        The metric name to use when searching for metric definitions.

        Example: CpuUtilization

        Parameters:
        name - the value to set
        Returns:
        this builder
      • namespace

        public ListMetricsDetails.Builder namespace​(String namespace)
        The source service or application to use when searching for metric definitions.

        Example: oci_computeagent

        Parameters:
        namespace - the value to set
        Returns:
        this builder
      • resourceGroup

        public ListMetricsDetails.Builder resourceGroup​(String resourceGroup)
        Resource group that you want to match.

        A null value returns only metric data that has no resource groups. The specified resource group must exist in the definition of the posted metric. 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

        Parameters:
        resourceGroup - the value to set
        Returns:
        this builder
      • dimensionFilters

        public ListMetricsDetails.Builder dimensionFilters​(Map<String,​String> dimensionFilters)
        Qualifiers that you want to use when searching for metric definitions.

        Available dimensions vary by metric namespace. Each dimension takes the form of a key-value pair.

        Example: {"resourceId": "ocid1.instance.region1.phx.exampleuniqueID"}

        Parameters:
        dimensionFilters - the value to set
        Returns:
        this builder
      • groupBy

        public ListMetricsDetails.Builder groupBy​(List<String> groupBy)
        Group metrics by these fields in the response.

        For example, to list all metric namespaces available in a compartment, groupBy the “namespace” field. Supported fields: namespace, name, resourceGroup. If groupBy is used, then dimensionFilters is ignored.

        Example - group by namespace: [ "namespace" ]

        Parameters:
        groupBy - the value to set
        Returns:
        this builder
      • sortBy

        public ListMetricsDetails.Builder sortBy​(ListMetricsDetails.SortBy sortBy)
        The field to use when sorting returned metric definitions.

        Only one sorting level is provided.

        Example: NAMESPACE

        Parameters:
        sortBy - the value to set
        Returns:
        this builder
      • sortOrder

        public ListMetricsDetails.Builder sortOrder​(ListMetricsDetails.SortOrder sortOrder)
        The sort order to use when sorting returned metric definitions.

        Ascending (ASC) or descending (DESC).

        Example: ASC

        Parameters:
        sortOrder - the value to set
        Returns:
        this builder