diff --git a/docs/data-sources/thanos.md b/docs/data-sources/thanos.md index 2eb347331..8db5a0d03 100644 --- a/docs/data-sources/thanos.md +++ b/docs/data-sources/thanos.md @@ -115,6 +115,7 @@ Read-Only: Read-Only: - `compactor` (List of Object) (see [below for nested schema](#nestedobjatt--thanos_user_config--compactor)) +- `env` (Map of String) - `ip_filter` (Set of String) - `ip_filter_object` (Set of Object) (see [below for nested schema](#nestedobjatt--thanos_user_config--ip_filter_object)) - `ip_filter_string` (Set of String) @@ -164,6 +165,8 @@ Read-Only: - `query_lookback_delta` (String) - `query_metadata_default_time_range` (String) - `query_timeout` (String) +- `store_limits_request_samples` (Number) +- `store_limits_request_series` (Number) diff --git a/docs/resources/opensearch.md b/docs/resources/opensearch.md index 175b4c723..ce353e785 100644 --- a/docs/resources/opensearch.md +++ b/docs/resources/opensearch.md @@ -242,7 +242,7 @@ Optional: - `action_destructive_requires_name` (Boolean) Require explicit index names when deleting. - `auth_failure_listeners` (Block List, Max: 1) Opensearch Security Plugin Settings (see [below for nested schema](#nestedblock--opensearch_user_config--opensearch--auth_failure_listeners)) - `cluster_max_shards_per_node` (Number) Controls the number of shards allowed in the cluster per data node. Example: `1000`. -- `cluster_routing_allocation_node_concurrent_recoveries` (Number) How many concurrent incoming/outgoing shard recoveries (normally replicas) are allowed to happen on a node. Defaults to 2. +- `cluster_routing_allocation_node_concurrent_recoveries` (Number) How many concurrent incoming/outgoing shard recoveries (normally replicas) are allowed to happen on a node. Defaults to node cpu count * 2. - `email_sender_name` (String) Sender name placeholder to be used in Opensearch Dashboards and Opensearch keystore. Example: `alert-sender`. - `email_sender_password` (String, Sensitive) Sender password for Opensearch alerts to authenticate with SMTP server. Example: `very-secure-mail-password`. - `email_sender_username` (String) Sender username for Opensearch alerts. Example: `jane@example.com`. diff --git a/docs/resources/thanos.md b/docs/resources/thanos.md index b48cef46a..1294d2397 100644 --- a/docs/resources/thanos.md +++ b/docs/resources/thanos.md @@ -107,6 +107,7 @@ Read-Only: Optional: - `compactor` (Block List, Max: 1) ThanosCompactor (see [below for nested schema](#nestedblock--thanos_user_config--compactor)) +- `env` (Map of String) Environmental variables. - `ip_filter` (Set of String, Deprecated) Allow incoming connections from CIDR address block, e.g. `10.20.0.0/16`. - `ip_filter_object` (Block Set, Max: 1024) Allow incoming connections from CIDR address block, e.g. `10.20.0.0/16` (see [below for nested schema](#nestedblock--thanos_user_config--ip_filter_object)) - `ip_filter_string` (Set of String) Allow incoming connections from CIDR address block, e.g. `10.20.0.0/16`. @@ -159,6 +160,8 @@ Optional: - `query_lookback_delta` (String) The maximum lookback duration for retrieving metrics during expression evaluations in PromQL. PromQL always evaluates the query for a certain timestamp, and it looks back for the given amount of time to get the latest sample. If it exceeds the maximum lookback delta, it assumes the series is stale and returns none (a gap). The lookback delta should be set to at least 2 times the slowest scrape interval. If unset, it will use the promql default of 5m. Default: `5m`. - `query_metadata_default_time_range` (String) The default metadata time range duration for retrieving labels through Labels and Series API when the range parameters are not specified. The zero value means the range covers the time since the beginning. Default: `0s`. - `query_timeout` (String) Maximum time to process a query by the query node. Default: `2m`. +- `store_limits_request_samples` (Number) The maximum samples allowed for a single Series request. The Series call fails if this limit is exceeded. Set to 0 for no limit. NOTE: For efficiency, the limit is internally implemented as 'chunks limit' considering each chunk contains a maximum of 120 samples. The default value is 100 * store.limits.request-series. Default: `0`. +- `store_limits_request_series` (Number) The maximum series allowed for a single Series request. The Series call fails if this limit is exceeded. Set to 0 for no limit. The default value is 1000 * cpu_count. Default: `0`. diff --git a/internal/sdkprovider/userconfig/service/opensearch.go b/internal/sdkprovider/userconfig/service/opensearch.go index e8cf4bc26..758065f08 100644 --- a/internal/sdkprovider/userconfig/service/opensearch.go +++ b/internal/sdkprovider/userconfig/service/opensearch.go @@ -441,7 +441,7 @@ func opensearchUserConfig() *schema.Schema { Type: schema.TypeInt, }, "cluster_routing_allocation_node_concurrent_recoveries": { - Description: "How many concurrent incoming/outgoing shard recoveries (normally replicas) are allowed to happen on a node. Defaults to 2.", + Description: "How many concurrent incoming/outgoing shard recoveries (normally replicas) are allowed to happen on a node. Defaults to node cpu count * 2.", Optional: true, Type: schema.TypeInt, }, diff --git a/internal/sdkprovider/userconfig/service/service.go b/internal/sdkprovider/userconfig/service/service.go index e724e37f2..b45d8107b 100644 --- a/internal/sdkprovider/userconfig/service/service.go +++ b/internal/sdkprovider/userconfig/service/service.go @@ -123,6 +123,8 @@ func GetFieldMapping(kind string) map[string]string { "query/query_lookback_delta": "query/query.lookback-delta", "query/query_metadata_default_time_range": "query/query.metadata.default-time-range", "query/query_timeout": "query/query.timeout", + "query/store_limits_request_samples": "query/store.limits.request-samples", + "query/store_limits_request_series": "query/store.limits.request-series", "query_frontend": "query-frontend", "query_frontend/query_range_align_range_with_step": "query-frontend/query-range.align-range-with-step", }, diff --git a/internal/sdkprovider/userconfig/service/thanos.go b/internal/sdkprovider/userconfig/service/thanos.go index a97d60e6c..6ff5a418d 100644 --- a/internal/sdkprovider/userconfig/service/thanos.go +++ b/internal/sdkprovider/userconfig/service/thanos.go @@ -24,6 +24,11 @@ func thanosUserConfig() *schema.Schema { Optional: true, Type: schema.TypeList, }, + "env": { + Description: "Environmental variables.", + Optional: true, + Type: schema.TypeMap, + }, "ip_filter": { Deprecated: "Deprecated. Use `ip_filter_string` instead.", Description: "Allow incoming connections from CIDR address block, e.g. `10.20.0.0/16`.", @@ -129,6 +134,16 @@ func thanosUserConfig() *schema.Schema { Optional: true, Type: schema.TypeString, }, + "store_limits_request_samples": { + Description: "The maximum samples allowed for a single Series request. The Series call fails if this limit is exceeded. Set to 0 for no limit. NOTE: For efficiency, the limit is internally implemented as 'chunks limit' considering each chunk contains a maximum of 120 samples. The default value is 100 * store.limits.request-series. Default: `0`.", + Optional: true, + Type: schema.TypeInt, + }, + "store_limits_request_series": { + Description: "The maximum series allowed for a single Series request. The Series call fails if this limit is exceeded. Set to 0 for no limit. The default value is 1000 * cpu_count. Default: `0`.", + Optional: true, + Type: schema.TypeInt, + }, }}, MaxItems: 1, Optional: true,