Reference documentation and code samples for the Cloud Monitoring V3 API class Google::Cloud::Monitoring::V3::ListMetricDescriptorsRequest.
The ListMetricDescriptors request.
Inherits
Object
Extended By
Google::Protobuf::MessageExts::ClassMethods
Includes
Google::Protobuf::MessageExts
Methods
#active_only
defactive_only()->::Boolean
Returns
(::Boolean) —
Optional. If true, only metrics and monitored resource types that have
recent data (within roughly 25 hours) will be included in the response.
If a metric descriptor enumerates monitored resource types, only the
monitored resource types for which the metric type has recent data will
be included in the returned metric descriptor, and if none of them have
recent data, the metric descriptor will not be returned.
If a metric descriptor does not enumerate the compatible monitored
resource types, it will be returned only if the metric type has recent
data for some monitored resource type. The returned descriptor will not
enumerate any monitored resource types.
#active_only=
defactive_only=(value)->::Boolean
Parameter
value (::Boolean) —
Optional. If true, only metrics and monitored resource types that have
recent data (within roughly 25 hours) will be included in the response.
If a metric descriptor enumerates monitored resource types, only the
monitored resource types for which the metric type has recent data will
be included in the returned metric descriptor, and if none of them have
recent data, the metric descriptor will not be returned.
If a metric descriptor does not enumerate the compatible monitored
resource types, it will be returned only if the metric type has recent
data for some monitored resource type. The returned descriptor will not
enumerate any monitored resource types.
Returns
(::Boolean) —
Optional. If true, only metrics and monitored resource types that have
recent data (within roughly 25 hours) will be included in the response.
If a metric descriptor enumerates monitored resource types, only the
monitored resource types for which the metric type has recent data will
be included in the returned metric descriptor, and if none of them have
recent data, the metric descriptor will not be returned.
If a metric descriptor does not enumerate the compatible monitored
resource types, it will be returned only if the metric type has recent
data for some monitored resource type. The returned descriptor will not
enumerate any monitored resource types.
#filter
deffilter()->::String
Returns
(::String) —
Optional. If this field is empty, all custom and
system-defined metric descriptors are returned.
Otherwise, the filter
specifies which metric descriptors are to be
returned. For example, the following filter matches all
custom metrics:
Optional. If this field is empty, all custom and
system-defined metric descriptors are returned.
Otherwise, the filter
specifies which metric descriptors are to be
returned. For example, the following filter matches all
custom metrics:
Optional. If this field is empty, all custom and
system-defined metric descriptors are returned.
Otherwise, the filter
specifies which metric descriptors are to be
returned. For example, the following filter matches all
custom metrics:
Required. The
project on which
to execute the request. The format is:
projects/[PROJECT_ID_OR_NUMBER]
#name=
defname=(value)->::String
Parameter
value (::String) —
Required. The
project on which
to execute the request. The format is:
projects/[PROJECT_ID_OR_NUMBER]
Returns
(::String) —
Required. The
project on which
to execute the request. The format is:
projects/[PROJECT_ID_OR_NUMBER]
#page_size
defpage_size()->::Integer
Returns
(::Integer) — Optional. A positive number that is the maximum number of results to
return. The default and maximum value is 10,000. If a page_size <= 0 or >
10,000 is submitted, will instead return a maximum of 10,000 results.
#page_size=
defpage_size=(value)->::Integer
Parameter
value (::Integer) — Optional. A positive number that is the maximum number of results to
return. The default and maximum value is 10,000. If a page_size <= 0 or >
10,000 is submitted, will instead return a maximum of 10,000 results.
Returns
(::Integer) — Optional. A positive number that is the maximum number of results to
return. The default and maximum value is 10,000. If a page_size <= 0 or >
10,000 is submitted, will instead return a maximum of 10,000 results.
#page_token
defpage_token()->::String
Returns
(::String) — Optional. If this field is not empty then it must contain the
nextPageToken value returned by a previous call to this method. Using
this field causes the method to return additional results from the previous
method call.
#page_token=
defpage_token=(value)->::String
Parameter
value (::String) — Optional. If this field is not empty then it must contain the
nextPageToken value returned by a previous call to this method. Using
this field causes the method to return additional results from the previous
method call.
Returns
(::String) — Optional. If this field is not empty then it must contain the
nextPageToken value returned by a previous call to this method. Using
this field causes the method to return additional results from the previous
method call.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Cloud Monitoring V3 API - Class Google::Cloud::Monitoring::V3::ListMetricDescriptorsRequest (v1.6.1)\n\nVersion latestkeyboard_arrow_down\n\n- [1.6.1 (latest)](/ruby/docs/reference/google-cloud-monitoring-v3/latest/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [1.6.0](/ruby/docs/reference/google-cloud-monitoring-v3/1.6.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [1.5.1](/ruby/docs/reference/google-cloud-monitoring-v3/1.5.1/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [1.4.0](/ruby/docs/reference/google-cloud-monitoring-v3/1.4.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [1.3.0](/ruby/docs/reference/google-cloud-monitoring-v3/1.3.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [1.2.0](/ruby/docs/reference/google-cloud-monitoring-v3/1.2.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [1.1.0](/ruby/docs/reference/google-cloud-monitoring-v3/1.1.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [1.0.1](/ruby/docs/reference/google-cloud-monitoring-v3/1.0.1/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.18.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.18.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.17.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.17.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.16.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.16.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.15.2](/ruby/docs/reference/google-cloud-monitoring-v3/0.15.2/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.14.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.14.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.13.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.13.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.12.1](/ruby/docs/reference/google-cloud-monitoring-v3/0.12.1/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.11.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.11.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.10.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.10.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.9.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.9.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.8.0](/ruby/docs/reference/google-cloud-monitoring-v3/0.8.0/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest)\n- [0.7.1](/ruby/docs/reference/google-cloud-monitoring-v3/0.7.1/Google-Cloud-Monitoring-V3-ListMetricDescriptorsRequest) \nReference documentation and code samples for the Cloud Monitoring V3 API class Google::Cloud::Monitoring::V3::ListMetricDescriptorsRequest.\n\nThe `ListMetricDescriptors` request. \n\nInherits\n--------\n\n- Object \n\nExtended By\n-----------\n\n- Google::Protobuf::MessageExts::ClassMethods \n\nIncludes\n--------\n\n- Google::Protobuf::MessageExts\n\nMethods\n-------\n\n### #active_only\n\n def active_only() -\u003e ::Boolean\n\n**Returns**\n\n- (::Boolean) --- Optional. If true, only metrics and monitored resource types that have\n recent data (within roughly 25 hours) will be included in the response.\n\n - If a metric descriptor enumerates monitored resource types, only the monitored resource types for which the metric type has recent data will be included in the returned metric descriptor, and if none of them have recent data, the metric descriptor will not be returned.\n - If a metric descriptor does not enumerate the compatible monitored resource types, it will be returned only if the metric type has recent data for some monitored resource type. The returned descriptor will not enumerate any monitored resource types.\n\n### #active_only=\n\n def active_only=(value) -\u003e ::Boolean\n\n**Parameter**\n\n- **value** (::Boolean) ---\n\n Optional. If true, only metrics and monitored resource types that have\n recent data (within roughly 25 hours) will be included in the response.\n - If a metric descriptor enumerates monitored resource types, only the monitored resource types for which the metric type has recent data will be included in the returned metric descriptor, and if none of them have recent data, the metric descriptor will not be returned.\n- If a metric descriptor does not enumerate the compatible monitored resource types, it will be returned only if the metric type has recent data for some monitored resource type. The returned descriptor will not enumerate any monitored resource types. \n**Returns**\n\n- (::Boolean) --- Optional. If true, only metrics and monitored resource types that have\n recent data (within roughly 25 hours) will be included in the response.\n\n - If a metric descriptor enumerates monitored resource types, only the monitored resource types for which the metric type has recent data will be included in the returned metric descriptor, and if none of them have recent data, the metric descriptor will not be returned.\n - If a metric descriptor does not enumerate the compatible monitored resource types, it will be returned only if the metric type has recent data for some monitored resource type. The returned descriptor will not enumerate any monitored resource types.\n\n### #filter\n\n def filter() -\u003e ::String\n\n**Returns**\n\n- (::String) --- Optional. If this field is empty, all custom and\n system-defined metric descriptors are returned.\n Otherwise, the [filter](https://cloud.google.com/monitoring/api/v3/filters)\n specifies which metric descriptors are to be\n returned. For example, the following filter matches all\n [custom metrics](https://cloud.google.com/monitoring/custom-metrics):\n\n metric.type = starts_with(\"custom.googleapis.com/\")\n\n### #filter=\n\n def filter=(value) -\u003e ::String\n\n**Parameter**\n\n- **value** (::String) ---\n\n Optional. If this field is empty, all custom and\n system-defined metric descriptors are returned.\n Otherwise, the [filter](https://cloud.google.com/monitoring/api/v3/filters)\n specifies which metric descriptors are to be\n returned. For example, the following filter matches all\n [custom metrics](https://cloud.google.com/monitoring/custom-metrics): \n\n metric.type = starts_with(\"custom.googleapis.com/\")\n\n**Returns**\n\n- (::String) --- Optional. If this field is empty, all custom and\n system-defined metric descriptors are returned.\n Otherwise, the [filter](https://cloud.google.com/monitoring/api/v3/filters)\n specifies which metric descriptors are to be\n returned. For example, the following filter matches all\n [custom metrics](https://cloud.google.com/monitoring/custom-metrics):\n\n metric.type = starts_with(\"custom.googleapis.com/\")\n\n### #name\n\n def name() -\u003e ::String\n\n**Returns**\n\n- (::String) --- Required. The\n [project](https://cloud.google.com/monitoring/api/v3#project_name) on which\n to execute the request. The format is:\n\n projects/[PROJECT_ID_OR_NUMBER]\n\n### #name=\n\n def name=(value) -\u003e ::String\n\n**Parameter**\n\n- **value** (::String) ---\n\n Required. The\n [project](https://cloud.google.com/monitoring/api/v3#project_name) on which\n to execute the request. The format is: \n\n projects/[PROJECT_ID_OR_NUMBER]\n\n**Returns**\n\n- (::String) --- Required. The\n [project](https://cloud.google.com/monitoring/api/v3#project_name) on which\n to execute the request. The format is:\n\n projects/[PROJECT_ID_OR_NUMBER]\n\n### #page_size\n\n def page_size() -\u003e ::Integer\n\n**Returns**\n\n- (::Integer) --- Optional. A positive number that is the maximum number of results to return. The default and maximum value is 10,000. If a page_size \\\u003c= 0 or \\\u003e 10,000 is submitted, will instead return a maximum of 10,000 results.\n\n### #page_size=\n\n def page_size=(value) -\u003e ::Integer\n\n**Parameter**\n\n- **value** (::Integer) --- Optional. A positive number that is the maximum number of results to return. The default and maximum value is 10,000. If a page_size \\\u003c= 0 or \\\u003e 10,000 is submitted, will instead return a maximum of 10,000 results. \n**Returns**\n\n- (::Integer) --- Optional. A positive number that is the maximum number of results to return. The default and maximum value is 10,000. If a page_size \\\u003c= 0 or \\\u003e 10,000 is submitted, will instead return a maximum of 10,000 results.\n\n### #page_token\n\n def page_token() -\u003e ::String\n\n**Returns**\n\n- (::String) --- Optional. If this field is not empty then it must contain the `nextPageToken` value returned by a previous call to this method. Using this field causes the method to return additional results from the previous method call.\n\n### #page_token=\n\n def page_token=(value) -\u003e ::String\n\n**Parameter**\n\n- **value** (::String) --- Optional. If this field is not empty then it must contain the `nextPageToken` value returned by a previous call to this method. Using this field causes the method to return additional results from the previous method call. \n**Returns**\n\n- (::String) --- Optional. If this field is not empty then it must contain the `nextPageToken` value returned by a previous call to this method. Using this field causes the method to return additional results from the previous method call."]]