diff --git a/content/enterprise_influxdb/v1/tools/api.md b/content/enterprise_influxdb/v1/tools/api.md index 0666e77d27..ccaf6439fb 100644 --- a/content/enterprise_influxdb/v1/tools/api.md +++ b/content/enterprise_influxdb/v1/tools/api.md @@ -16,9 +16,9 @@ It uses HTTP response codes, authentication with username and password credentia The following sections assume your InfluxDB instance is running on `localhost` port `8086` and HTTPS is not enabled. -Those settings [are configurable](/enterprise_influxdb/v1/administration/configure/config-data-nodes/#http-endpoints-settings). +Those settings [are configurable](/enterprise_influxdb/v1/administration/configure/config-data-nodes/#http-endpoint-settings). -- [InfluxDB 2.x API compatibility endpoints](#influxdb-20-api-compatibility-endpoints) +- [InfluxDB 2.x API compatibility endpoints](#influxdb-2x-api-compatibility-endpoints) - [InfluxDB 1.x HTTP endpoints](#influxdb-1x-http-endpoints) ## InfluxDB 2.x API compatibility endpoints @@ -49,14 +49,14 @@ The following forward compatible APIs are available: ### `/api/v2/query/` HTTP endpoint The `/api/v2/query` endpoint accepts `POST` HTTP requests. -Use this endpoint to query data using [Flux](/enterprise_influxdb/v1/flux/) and [InfluxDB 2.x client libraries](/influxdb/v2.x/api-guide/client-libraries/). +Use this endpoint to query data using [Flux](/enterprise_influxdb/v1/flux/) and [InfluxDB 2.x client libraries](/influxdb/v2/api-guide/client-libraries/). Flux is the primary language for working with data in InfluxDB 2.x. **Include the following HTTP headers:** - `Accept: application/csv` - `Content-type: application/vnd.flux` -- If [authentication is enabled](/enterprise_influxdb/v1/administration/authentication_and_authorization), +- If [authentication is enabled](/enterprise_influxdb/v1/administration/configure/security/authentication/), provide your InfluxDB username and password: `Authorization: Token USERNAME:PASSWORD` @@ -397,6 +397,58 @@ For information about InfluxDB HTTP server metrics, see the [`httpd` measurement >**Note:** The [InfluxDB input plugin](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/influxdb) is available to collect metrics (using the `/debug/vars` endpoint) from specified Kapacitor instances. For a list of the measurements and fields, see the [InfluxDB input plugin README](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/influxdb#readme). +#### Running configuration {metadata="v1.12.3+"} + +The `/debug/vars` response includes a `config` key that contains the running [TSDB storage configuration](/enterprise_influxdb/v1/administration/configure/config-data-nodes/#data-settings). +Use this to inspect active server settings without direct access to configuration files. + +Values in the JSON output use the following representations: + +- Size values (such as `cache-max-memory-size`) appear as integers in bytes. +- Duration values (such as `cache-snapshot-write-cold-duration`) appear as human-readable strings (for example, `"10m0s"`). + +The output is similar to the following: + +```json +{ + "config": { + "cache-max-memory-size": 1073741824, + "cache-snapshot-memory-size": 26214400, + "cache-snapshot-write-cold-duration": "10m0s", + "compact-full-write-cold-duration": "4h0m0s", + "compact-throughput": 50331648, + "compact-throughput-burst": 50331648, + "dir": "/var/lib/influxdb/data", + "max-concurrent-compactions": 0, + "max-index-log-file-size": 1048576, + "max-series-per-database": 1000000, + "max-values-per-tag": 100000, + "series-id-set-cache-size": 100, + "wal-dir": "/var/lib/influxdb/wal", + "wal-fsync-delay": "0s" + } +} +``` + +> [!Note] +> InfluxDB Enterprise data nodes also expose [cluster configuration](/enterprise_influxdb/v1/administration/configure/config-data-nodes/#cluster-settings) fields through their own diagnostics, including `dial-timeout`, `shard-reader-timeout`, and `rpc-resettable-*-timeout` settings. + +#### Continuous query statistics {metadata="v1.12.3+"} + +The `/debug/vars` response includes a `cq` key with continuous query execution counters: + +```json +{ + "cq": { + "queryOk": 2, + "queryFail": 0 + } +} +``` + +- `queryOk`: Number of CQ executions that completed successfully. +- `queryFail`: Number of CQ executions that failed. + ### `/ping` HTTP endpoint The ping endpoint accepts both `GET` and `HEAD` HTTP requests. @@ -537,7 +589,7 @@ A successful [`CREATE DATABASE` query](/enterprise_influxdb/v1/query_language/ma | chunked=[true \| \] | Optional | Returns points in streamed batches instead of in a single response. If set to `true`, InfluxDB chunks responses by series or by every 10,000 points, whichever occurs first. If set to a specific value, InfluxDB chunks responses by series or by that number of points.* | | db=\ | Required for database-dependent queries (most [`SELECT`](/enterprise_influxdb/v1/query_language/spec/#select) queries and [`SHOW`](/enterprise_influxdb/v1/query_language/spec/#show-continuous-queries) queries require this parameter). | Sets the target [database](/enterprise_influxdb/v1/concepts/glossary/#database) for the query. | | epoch=[ns,u,µ,ms,s,m,h] | Optional | Returns epoch timestamps with the specified precision. By default, InfluxDB returns timestamps in RFC3339 format with nanosecond precision. Both `u` and `µ` indicate microseconds. | -| p=\ | Optional if you haven't [enabled authentication](/enterprise_influxdb/v1/administration/authentication_and_authorization/#set-up-authentication). Required if you've enabled authentication.** | Sets the password for authentication if you've enabled authentication. Use with the query string parameter `u`. | +| p=\ | Optional if you haven't [enabled authentication](/enterprise_influxdb/v1/administration/configure/security/authentication/#enable-authentication). Required if you've enabled authentication.** | Sets the password for authentication if you've enabled authentication. Use with the query string parameter `u`. | | pretty=true | Optional | Enables pretty-printed JSON output. While this is useful for debugging it is not recommended for production use as it consumes unnecessary network bandwidth. | | q=\ | Required | InfluxQL string to execute. See also [Request Body](/enterprise_influxdb/v1/tools/api/#request-body). | | time_format=[epoch \| rfc3339] | Optional | Sets the timestamp format in query responses. `epoch` _(default)_ returns epoch timestamps (use with the `epoch` parameter to set precision). `rfc3339` returns timestamps as RFC3339Nano-formatted strings (for example, `2017-03-01T00:16:18.000000000Z`). Returns `400` if set to an invalid value. _Available in InfluxDB Enterprise v1.12.3+._ | @@ -548,7 +600,7 @@ That behavior is configurable; see the [`max-row-limit`](/enterprise_influxdb/v1 configuration option for more information. \** The InfluxDB API also supports basic authentication. -Use basic authentication if you've [enabled authentication](/enterprise_influxdb/v1/administration/authentication_and_authorization/#set-up-authentication) +Use basic authentication if you've [enabled authentication](/enterprise_influxdb/v1/administration/configure/security/authentication/#enable-authentication) and aren't using the query string parameters `u` and `p`. See below for an [example](#create-a-database-using-basic-authentication) of basic authentication. @@ -942,13 +994,13 @@ POST http://localhost:8086/write | :--------------------- | :---------------- | :---------- | | consistency=[any,one,quorum,all] | Optional, available with [InfluxDB Enterprise clusters](/enterprise_influxdb/v1/) only. | Sets the write consistency for the point. InfluxDB assumes that the write consistency is `one` if you do not specify `consistency`. See the [InfluxDB Enterprise documentation](/enterprise_influxdb/v1/concepts/clustering#write-consistency) for detailed descriptions of each consistency option. | | db=\ | Required | Sets the target [database](/enterprise_influxdb/v1/concepts/glossary/#database) for the write. | -| p=\ | Optional if you haven't [enabled authentication](/enterprise_influxdb/v1/administration/authentication_and_authorization/#set-up-authentication). Required if you've enabled authentication.* | Sets the password for authentication if you've enabled authentication. Use with the query string parameter `u`. | +| p=\ | Optional if you haven't [enabled authentication](/enterprise_influxdb/v1/administration/configure/security/authentication/#enable-authentication). Required if you've enabled authentication.* | Sets the password for authentication if you've enabled authentication. Use with the query string parameter `u`. | | precision=[ns,u,ms,s,m,h] | Optional | Sets the precision for the supplied Unix time values. InfluxDB assumes that timestamps are in nanoseconds if you do not specify `precision`.** | | rp=\ | Optional | Sets the target [retention policy](/enterprise_influxdb/v1/concepts/glossary/#retention-policy-rp) for the write. InfluxDB writes to the `DEFAULT` retention policy if you do not specify a retention policy. | -| u=\ | Optional if you haven't [enabled authentication](/enterprise_influxdb/v1/administration/authentication_and_authorization/#set-up-authentication). Required if you've enabled authentication.* | Sets the username for authentication if you've enabled authentication. The user must have write access to the database. Use with the query string parameter `p`. | +| u=\ | Optional if you haven't [enabled authentication](/enterprise_influxdb/v1/administration/configure/security/authentication/#enable-authentication). Required if you've enabled authentication.* | Sets the username for authentication if you've enabled authentication. The user must have write access to the database. Use with the query string parameter `p`. | \* The InfluxDB API also supports basic authentication. -Use basic authentication if you've [enabled authentication](/enterprise_influxdb/v1/administration/authentication_and_authorization/#set-up-authentication) +Use basic authentication if you've [enabled authentication](/enterprise_influxdb/v1/administration/configure/security/authentication/#enable-authentication) and aren't using the query string parameters `u` and `p`. See below for an [example](#write-a-point-to-the-database-mydb-using-basic-authentication) of basic authentication. diff --git a/content/influxdb/v1/about_the_project/release-notes.md b/content/influxdb/v1/about_the_project/release-notes.md index 97f42931db..661bc20415 100644 --- a/content/influxdb/v1/about_the_project/release-notes.md +++ b/content/influxdb/v1/about_the_project/release-notes.md @@ -23,7 +23,7 @@ alt_links: - Add [`advanced-expiration` TLS configuration option](/influxdb/v1/administration/config/#advanced-expiration) to configure how far in advance to log warnings about TLS certificate expiration. - Add TLS certificate reloading on `SIGHUP`. -- Add `config` and `cq` (continuous query) diagnostics to the `/debug/vars` endpoint. +- Add [`config`](/influxdb/v1/tools/api/#running-configuration) and [`cq` (continuous query) statistics](/influxdb/v1/tools/api/#continuous-query-statistics) to the `/debug/vars` endpoint. - Improve dropped point logging. - Show user when displaying or logging queries. - Add [`time_format` parameter](/influxdb/v1/tools/api/#query-data-with-a-select-statement-and-the-time_format-parameter) for the HTTP API. diff --git a/content/influxdb/v1/tools/api.md b/content/influxdb/v1/tools/api.md index 5a3f5d4bae..dc8fed2e1c 100644 --- a/content/influxdb/v1/tools/api.md +++ b/content/influxdb/v1/tools/api.md @@ -64,8 +64,8 @@ InfluxDB v1 supports the following v2-compatible APIs: | Endpoint | Description | | :--------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------ | -| [/api/v2/query](#api-v2-query-http-endpoint) | Query data in InfluxDB 1.8.0+ using the InfluxDB v2 API and [Flux](/flux/latest/) | -| [/api/v2/write](#api-v2-write-http-endpoint) | Write data to InfluxDB 1.8.0+ using the InfluxDB v2 API _(compatible with InfluxDB v2 client libraries)_ | +| [/api/v2/query](#apiv2query-http-endpoint) | Query data in InfluxDB 1.8.0+ using the InfluxDB v2 API and [Flux](/flux/latest/) | +| [/api/v2/write](#apiv2write-http-endpoint) | Write data to InfluxDB 1.8.0+ using the InfluxDB v2 API _(compatible with InfluxDB v2 client libraries)_ | | [/api/v2/buckets](#apiv2buckets-http-endpoint) | Allows some client code using buckets to run against 1.x and 2.x without modification | | [/api/v2/delete](#apiv2delete-http-endpoint) | Supports deletion by tag value, timestamp, and measurement using the InfluxDB v2 API _(compatible with InfluxDB v2 client libraries)_ | | [/health](#health-http-endpoint) | Check the health of your InfluxDB instance | @@ -284,9 +284,9 @@ The following InfluxDB 1.x API endpoints are available: | Endpoint | Description | |:---------- |:---------- | -| [/debug/pprof ](#debug-pprof-http-endpoint) | Generate profiles for troubleshooting | -| [/debug/requests](#debug-requests-http-endpoint) | Track HTTP client requests to the `/write` and `/query` endpoints | -| [/debug/vars](#debug-vars-http-endpoint) | Collect internal InfluxDB statistics | +| [/debug/pprof ](#debugpprof-http-endpoint) | Generate profiles for troubleshooting | +| [/debug/requests](#debugrequests-http-endpoint) | Track HTTP client requests to the `/write` and `/query` endpoints | +| [/debug/vars](#debugvars-http-endpoint) | Collect internal InfluxDB statistics | | [/ping](#ping-http-endpoint) | Check the status of your InfluxDB instance and your version of InfluxDB | | [/query](#query-http-endpoint) | Query data using **InfluxQL**, manage databases, retention policies, and users | | [/write](#write-http-endpoint) | Write data to a database | @@ -420,6 +420,55 @@ For information about InfluxDB HTTP server metrics, see the [`httpd` measurement >**Note:** The [InfluxDB input plugin](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/influxdb) is available to collect metrics (using the `/debug/vars` endpoint) from specified Kapacitor instances. For a list of the measurements and fields, see the [InfluxDB input plugin README](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/influxdb#readme). +#### Running configuration {metadata="v1.12.3+"} + +The `/debug/vars` response includes a `config` key that contains the running [TSDB storage configuration](/influxdb/v1/administration/config/#data-settings). +Use this to inspect active server settings without direct access to configuration files. + +Values in the JSON output use the following representations: + +- Size values (such as `cache-max-memory-size`) appear as integers in bytes. +- Duration values (such as `cache-snapshot-write-cold-duration`) appear as human-readable strings (for example, `"10m0s"`). + +The output is similar to the following: + +```json +{ + "config": { + "cache-max-memory-size": 1073741824, + "cache-snapshot-memory-size": 26214400, + "cache-snapshot-write-cold-duration": "10m0s", + "compact-full-write-cold-duration": "4h0m0s", + "compact-throughput": 50331648, + "compact-throughput-burst": 50331648, + "dir": "/var/lib/influxdb/data", + "max-concurrent-compactions": 0, + "max-index-log-file-size": 1048576, + "max-series-per-database": 1000000, + "max-values-per-tag": 100000, + "series-id-set-cache-size": 100, + "wal-dir": "/var/lib/influxdb/wal", + "wal-fsync-delay": "0s" + } +} +``` + +#### Continuous query statistics {metadata="v1.12.3+"} + +The `/debug/vars` response includes a `cq` key with continuous query execution counters: + +```json +{ + "cq": { + "queryOk": 2, + "queryFail": 0 + } +} +``` + +- `queryOk`: Number of CQ executions that completed successfully. +- `queryFail`: Number of CQ executions that failed. + ### `/ping` HTTP endpoint The ping endpoint accepts both `GET` and `HEAD` HTTP requests. diff --git a/layouts/partials/article/feedback.html b/layouts/partials/article/feedback.html index c402dab9e9..14a930af50 100644 --- a/layouts/partials/article/feedback.html +++ b/layouts/partials/article/feedback.html @@ -2,7 +2,7 @@ {{ $product := index $productPathData 0 }} {{ $version := index $productPathData 1 }} {{ $productKey := cond (eq $product "influxdb3") (print "influxdb3_" (replaceRE "-" "_" $version)) $product }} -{{ $productNamespace := cond (eq $product "influxdb3") "influxdb" $product }} +{{ $productNamespace := cond (or (eq $product "influxdb3") (eq $product "enterprise_influxdb")) "influxdb" $product }} {{ $productName := (index .Site.Data.products $productKey).name }} {{ $supportBlacklist := slice "chronograf" "kapacitor" }}