Skip to content

Commit 3ed93a5

Browse files
cloudprovider: update docs with defaults (#2206)
1 parent b8365c8 commit 3ed93a5

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

docs/resources/cloud_provider_aws_cloudwatch_scrape_job.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ resource "grafana_cloud_provider_aws_cloudwatch_scrape_job" "test" {
8383
### Optional
8484

8585
- `custom_namespace` (Block List) Zero or more configuration blocks to configure custom namespaces for the AWS CloudWatch Scrape Job to scrape. Each block must have a distinct `name` attribute. When accessing this as an attribute reference, it is a list of objects. (see [below for nested schema](#nestedblock--custom_namespace))
86-
- `enabled` (Boolean) Whether the AWS CloudWatch Scrape Job is enabled or not.
87-
- `export_tags` (Boolean) When enabled, AWS resource tags are exported as Prometheus labels to metrics formatted as `aws_<service_name>_info`.
86+
- `enabled` (Boolean) Whether the AWS CloudWatch Scrape Job is enabled or not. Defaults to `true`.
87+
- `export_tags` (Boolean) When enabled, AWS resource tags are exported as Prometheus labels to metrics formatted as `aws_<service_name>_info`. Defaults to `true`.
8888
- `regions_subset_override` (Set of String) A subset of the regions that are configured in the associated AWS Account resource to apply to this scrape job. If not set or empty, all of the Account resource's regions are scraped.
8989
- `service` (Block List) One or more configuration blocks to configure AWS services for the AWS CloudWatch Scrape Job to scrape. Each block must have a distinct `name` attribute. When accessing this as an attribute reference, it is a list of objects. (see [below for nested schema](#nestedblock--service))
9090
- `static_labels` (Map of String) A set of static labels to add to all metrics exported by this scrape job.
@@ -104,7 +104,7 @@ Required:
104104
Optional:
105105

106106
- `metric` (Block List) One or more configuration blocks to configure metrics and their statistics to scrape. Each block must represent a distinct metric name. When accessing this as an attribute reference, it is a list of objects. (see [below for nested schema](#nestedblock--custom_namespace--metric))
107-
- `scrape_interval_seconds` (Number) The interval in seconds to scrape the custom namespace.
107+
- `scrape_interval_seconds` (Number) The interval in seconds to scrape the custom namespace. Defaults to `300`.
108108

109109
<a id="nestedblock--custom_namespace--metric"></a>
110110
### Nested Schema for `custom_namespace.metric`
@@ -127,7 +127,7 @@ Optional:
127127

128128
- `metric` (Block List) One or more configuration blocks to configure metrics and their statistics to scrape. Please note that AWS metric names must be supplied, and not their PromQL counterparts. Each block must represent a distinct metric name. When accessing this as an attribute reference, it is a list of objects. (see [below for nested schema](#nestedblock--service--metric))
129129
- `resource_discovery_tag_filter` (Block List) One or more configuration blocks to configure tag filters applied to discovery of resource entities in the associated AWS account. When accessing this as an attribute reference, it is a list of objects. (see [below for nested schema](#nestedblock--service--resource_discovery_tag_filter))
130-
- `scrape_interval_seconds` (Number) The interval in seconds to scrape the service. See https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/aws/cloudwatch-metrics/services/ for supported scrape intervals.
130+
- `scrape_interval_seconds` (Number) The interval in seconds to scrape the service. See https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/aws/cloudwatch-metrics/services/ for supported scrape intervals. Defaults to `300`.
131131
- `tags_to_add_to_metrics` (Set of String) A set of tags to add to all metrics exported by this scrape job, for use in PromQL queries.
132132

133133
<a id="nestedblock--service--metric"></a>

docs/resources/cloud_provider_aws_resource_metadata_scrape_job.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ resource "grafana_cloud_provider_aws_resource_metadata_scrape_job" "test" {
6363

6464
### Optional
6565

66-
- `enabled` (Boolean) Whether the AWS Resource Metadata Scrape Job is enabled or not.
66+
- `enabled` (Boolean) Whether the AWS Resource Metadata Scrape Job is enabled or not. Defaults to `true`.
6767
- `regions_subset_override` (Set of String) A subset of the regions that are configured in the associated AWS Account resource to apply to this scrape job. If not set or empty, all of the Account resource's regions are scraped.
6868
- `service` (Block List) One or more configuration blocks to configure AWS services for the Resource Metadata Scrape Job to scrape. Each block must have a distinct `name` attribute. When accessing this as an attribute reference, it is a list of objects. (see [below for nested schema](#nestedblock--service))
6969
- `static_labels` (Map of String) A set of static labels to add to all metrics exported by this scrape job.
@@ -83,7 +83,7 @@ Required:
8383
Optional:
8484

8585
- `resource_discovery_tag_filter` (Block List) One or more configuration blocks to configure tag filters applied to discovery of resource entities in the associated AWS account. When accessing this as an attribute reference, it is a list of objects. (see [below for nested schema](#nestedblock--service--resource_discovery_tag_filter))
86-
- `scrape_interval_seconds` (Number) The interval in seconds to scrape the service. See https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/aws/cloudwatch-metrics/services/ for supported scrape intervals.
86+
- `scrape_interval_seconds` (Number) The interval in seconds to scrape the service. See https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/aws/cloudwatch-metrics/services/ for supported scrape intervals. Defaults to `300`.
8787

8888
<a id="nestedblock--service--resource_discovery_tag_filter"></a>
8989
### Nested Schema for `service.resource_discovery_tag_filter`

internal/resources/cloudprovider/resource_aws_cloudwatch_scrape_job.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ func (r resourceAWSCloudWatchScrapeJob) Schema(ctx context.Context, req resource
8787
},
8888
},
8989
"enabled": schema.BoolAttribute{
90-
Description: "Whether the AWS CloudWatch Scrape Job is enabled or not.",
90+
Description: "Whether the AWS CloudWatch Scrape Job is enabled or not. Defaults to `true`.",
9191
Optional: true,
9292
Computed: true,
9393
Default: booldefault.StaticBool(true),
@@ -104,7 +104,7 @@ func (r resourceAWSCloudWatchScrapeJob) Schema(ctx context.Context, req resource
104104
Default: setdefault.StaticValue(types.SetValueMust(types.StringType, []attr.Value{})),
105105
},
106106
"export_tags": schema.BoolAttribute{
107-
Description: "When enabled, AWS resource tags are exported as Prometheus labels to metrics formatted as `aws_<service_name>_info`.",
107+
Description: "When enabled, AWS resource tags are exported as Prometheus labels to metrics formatted as `aws_<service_name>_info`. Defaults to `true`.",
108108
Optional: true,
109109
Computed: true,
110110
Default: booldefault.StaticBool(true),
@@ -135,7 +135,7 @@ func (r resourceAWSCloudWatchScrapeJob) Schema(ctx context.Context, req resource
135135
Required: true,
136136
},
137137
"scrape_interval_seconds": schema.Int64Attribute{
138-
Description: "The interval in seconds to scrape the service. See https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/aws/cloudwatch-metrics/services/ for supported scrape intervals.",
138+
Description: "The interval in seconds to scrape the service. See https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/aws/cloudwatch-metrics/services/ for supported scrape intervals. Defaults to `300`.",
139139
Optional: true,
140140
Computed: true,
141141
Default: int64default.StaticInt64(300),
@@ -202,7 +202,7 @@ func (r resourceAWSCloudWatchScrapeJob) Schema(ctx context.Context, req resource
202202
Required: true,
203203
},
204204
"scrape_interval_seconds": schema.Int64Attribute{
205-
Description: "The interval in seconds to scrape the custom namespace.",
205+
Description: "The interval in seconds to scrape the custom namespace. Defaults to `300`.",
206206
Optional: true,
207207
Computed: true,
208208
Default: int64default.StaticInt64(300),

internal/resources/cloudprovider/resource_aws_resource_metadata_scrape_job.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ func (r resourceAWSResourceMetadataScrapeJob) Schema(ctx context.Context, req re
8686
},
8787
},
8888
"enabled": schema.BoolAttribute{
89-
Description: "Whether the AWS Resource Metadata Scrape Job is enabled or not.",
89+
Description: "Whether the AWS Resource Metadata Scrape Job is enabled or not. Defaults to `true`.",
9090
Optional: true,
9191
Computed: true,
9292
Default: booldefault.StaticBool(true),
@@ -128,7 +128,7 @@ func (r resourceAWSResourceMetadataScrapeJob) Schema(ctx context.Context, req re
128128
Required: true,
129129
},
130130
"scrape_interval_seconds": schema.Int64Attribute{
131-
Description: "The interval in seconds to scrape the service. See https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/aws/cloudwatch-metrics/services/ for supported scrape intervals.",
131+
Description: "The interval in seconds to scrape the service. See https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/aws/cloudwatch-metrics/services/ for supported scrape intervals. Defaults to `300`.",
132132
Optional: true,
133133
Computed: true,
134134
Default: int64default.StaticInt64(300),

0 commit comments

Comments
 (0)