From cadf76f714703fe99c8e5aae223623086b1ca890 Mon Sep 17 00:00:00 2001 From: "Zsolt Gyulai (zgyulai)" Date: Wed, 2 Jul 2025 15:20:55 +0200 Subject: [PATCH 1/3] Editorial updates. Signed-off-by: Zsolt Gyulai (zgyulai) --- .../000_stats_exporter_source_options.md | 26 +++++++++---------- .../060_Sources/153_stats_exporter/README.md | 4 +-- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md b/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md index a981ff9..d3a678b 100644 --- a/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md +++ b/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md @@ -2,10 +2,10 @@ title: stats-exporter() source options id: adm-src--stats-exporter-opt description: >- - The stats-exporter() sources directly can serve the output of syslog-ng-ctl stats and syslog-ng-ctl query to a HTTP Scraper. Unlike the stats-exporter-dont-log() that suppresses log messages from incoming scraper requests, the stats-exporter() logs the unparsed messages, storing incoming scraper HTTP requests in the MSG field. + The `stats-exporter()` sources directly can serve the output of `syslog-ng-ctl` stats and `syslog-ng-ctl` query to an HTTP Scraper. Unlike the stats-exporter-dont-log() that suppresses log messages from incoming scraper requests, the `stats-exporter()` logs the unparsed messages, storing incoming scraper HTTP requests in the `MSG` field. --- -Technically, both sources are specialized versions of the network() source. See the network() source options for details. +Technically, both sources are specialized versions of the `network()` source. For more options and details, see the network() source options. >**NOTE:** A destination is not required for this source to work; the `stats-exporter()` sources will respond to the scraper regardless of whether a destination is present in the log path. {: .notice--info} @@ -17,43 +17,43 @@ These drivers have the following additional options: |Accepted values:| query \| stats | |Default: | stats | -*Description:* The stat type you wish to provide in the response to a HTTP Scraper request, just like for the syslog-ng-ctl command line tool. +*Description:* This option sets the desired stat type to be produced in response to an HTTP Scraper request. This method operates like the `syslog-ng-ctl` command line tool. ## stat-query() |Accepted values:| regular expression | |Default: | | -*Description:* The query regex string that can be used to filter the output of a `query` type request. +*Description:* This option sets the query regex string which can be used to filter the output of a query type request. ## stat-format() |Accepted values:| csv \| kv \| prometheus | |Default: | prometheus | -*Description:* Specifies the format of the statistics output in HTTP responses, similar to the options available in syslog-ng-ctl. The available formats are: +*Description:* This option specifies the format of the statistics output in HTTP responses, similar to the options available in `syslog-ng-ctl`. The available formats are the following: -- csv – comma-separated values format -- kv – key-value pairs, one per line -- prometheus – Prometheus-compatible exposition format +- `csv` – comma-separated values format +- `kv` – key-value pairs, one per line +- `prometheus` – Prometheus-compatible exposition format ## scrape-pattern() |Accepted values:| regular expression | -|Default: | GET /metrics* | +|Default: | `GET /metrics*` | -*Description:* The pattern used to match the HTTP header of incoming scraping requests. A stat response will be generated and sent only if the header matches the scrape-pattern(). +*Description:* This option sets the pattern used to match the HTTP header of incoming scraping requests. A stat response will be generated and sent only if the header matches the one set in the `scrape-pattern()` option. ## scrape-freq-limit() |Accepted values:| number | -|Default: | 0 | +|Default: | `0` | -*Description:* Limits the frequency of repeated scraper requests to the specified number of seconds. Any repeated request within this period will be ignored. A value of 0 means no limit. +*Description:* This option limits the frequency of repeated scraper requests to the specified number of seconds. Any repeated request within this period will be ignored. A set value of `0` means no limit. ## single-instance() |Accepted values:| yes \| no | |Default: | no | -*Description:* If set to `yes` only one scraper connection and request will be allowed at once. +*Description:* If this option is set to `yes`, only one scraper connection and request will be allowed at once. \ No newline at end of file diff --git a/doc/_admin-guide/060_Sources/153_stats_exporter/README.md b/doc/_admin-guide/060_Sources/153_stats_exporter/README.md index e7e8086..6ce0e89 100644 --- a/doc/_admin-guide/060_Sources/153_stats_exporter/README.md +++ b/doc/_admin-guide/060_Sources/153_stats_exporter/README.md @@ -30,7 +30,7 @@ log { }; ``` -Example usage for a generic HTTP Scraper which sends e.g. the `GET /stats HTTP/1.1` HTTP request to get statistics of {{ site.product.short_name }}, do not want to log or further process the HTTP requests in the log pipe, and needs the response in CSV format: +Example usage for a generic HTTP Scraper which sends the `GET /stats HTTP/1.1` HTTP request to get statistics of a syslog-ng PE system, which is not required to log or further process the HTTP requests in the log pipe, and needs the response in CSV format: ``` config @version: 4.9 @@ -53,5 +53,5 @@ log { }; ``` ->**NOTE:** A destination is not required for this to work; the `stats-exporter()` sources will respond to the scraper regardless of whether a destination is present in the log path. +>**NOTE:** A destination is not required for this to work. The `stats-exporter()` sources will respond to the scraper regardless of whether a destination is present in the log path or not. {: .notice--info} From fa97721092c813594a2a461cb28da0f0bbe447c4 Mon Sep 17 00:00:00 2001 From: "Zsolt Gyulai (zgyulai)" Date: Mon, 7 Jul 2025 13:27:34 +0200 Subject: [PATCH 2/3] Removed accidental instance of PE, and autolink breaking backticks. Signed-off-by: Zsolt Gyulai (zgyulai) --- .../153_stats_exporter/000_stats_exporter_source_options.md | 2 +- doc/_admin-guide/060_Sources/153_stats_exporter/README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md b/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md index d3a678b..130b05d 100644 --- a/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md +++ b/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md @@ -2,7 +2,7 @@ title: stats-exporter() source options id: adm-src--stats-exporter-opt description: >- - The `stats-exporter()` sources directly can serve the output of `syslog-ng-ctl` stats and `syslog-ng-ctl` query to an HTTP Scraper. Unlike the stats-exporter-dont-log() that suppresses log messages from incoming scraper requests, the `stats-exporter()` logs the unparsed messages, storing incoming scraper HTTP requests in the `MSG` field. + The stats-exporter() sources directly can serve the output of syslog-ng-ctl stats and syslog-ng-ctl query to an HTTP Scraper. Unlike the stats-exporter-dont-log() that suppresses log messages from incoming scraper requests, the stats-exporter() logs the unparsed messages, storing incoming scraper HTTP requests in the MSG field. --- Technically, both sources are specialized versions of the `network()` source. For more options and details, see the network() source options. diff --git a/doc/_admin-guide/060_Sources/153_stats_exporter/README.md b/doc/_admin-guide/060_Sources/153_stats_exporter/README.md index 6ce0e89..86d8d64 100644 --- a/doc/_admin-guide/060_Sources/153_stats_exporter/README.md +++ b/doc/_admin-guide/060_Sources/153_stats_exporter/README.md @@ -30,7 +30,7 @@ log { }; ``` -Example usage for a generic HTTP Scraper which sends the `GET /stats HTTP/1.1` HTTP request to get statistics of a syslog-ng PE system, which is not required to log or further process the HTTP requests in the log pipe, and needs the response in CSV format: +Example usage for a generic HTTP Scraper which sends the `GET /stats HTTP/1.1` HTTP request to get statistics of a {{ site.product.short_name }} system, which is not required to log or further process the HTTP requests in the log pipe, and needs the response in CSV format: ``` config @version: 4.9 From 954a8348baf24bbf400a0ee0e9bd586f87fbf38a Mon Sep 17 00:00:00 2001 From: "Zsolt Gyulai (zgyulai)" Date: Mon, 7 Jul 2025 14:48:58 +0200 Subject: [PATCH 3/3] Removed more backticks to preserve autolinks. Signed-off-by: Zsolt Gyulai (zgyulai) --- .../000_stats_exporter_source_options.md | 8 ++++---- doc/_admin-guide/060_Sources/153_stats_exporter/README.md | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md b/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md index 130b05d..a5b969f 100644 --- a/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md +++ b/doc/_admin-guide/060_Sources/153_stats_exporter/000_stats_exporter_source_options.md @@ -5,9 +5,9 @@ description: >- The stats-exporter() sources directly can serve the output of syslog-ng-ctl stats and syslog-ng-ctl query to an HTTP Scraper. Unlike the stats-exporter-dont-log() that suppresses log messages from incoming scraper requests, the stats-exporter() logs the unparsed messages, storing incoming scraper HTTP requests in the MSG field. --- -Technically, both sources are specialized versions of the `network()` source. For more options and details, see the network() source options. +Technically, both sources are specialized versions of the network() source. For more options and details, see the network() source options. ->**NOTE:** A destination is not required for this source to work; the `stats-exporter()` sources will respond to the scraper regardless of whether a destination is present in the log path. +>**NOTE:** A destination is not required for this source to work; the stats-exporter() sources will respond to the scraper regardless of whether a destination is present in the log path. {: .notice--info} These drivers have the following additional options: @@ -17,7 +17,7 @@ These drivers have the following additional options: |Accepted values:| query \| stats | |Default: | stats | -*Description:* This option sets the desired stat type to be produced in response to an HTTP Scraper request. This method operates like the `syslog-ng-ctl` command line tool. +*Description:* This option sets the desired stat type to be produced in response to an HTTP Scraper request. This method operates like the syslog-ng-ctl command line tool. ## stat-query() @@ -31,7 +31,7 @@ These drivers have the following additional options: |Accepted values:| csv \| kv \| prometheus | |Default: | prometheus | -*Description:* This option specifies the format of the statistics output in HTTP responses, similar to the options available in `syslog-ng-ctl`. The available formats are the following: +*Description:* This option specifies the format of the statistics output in HTTP responses, similar to the options available in syslog-ng-ctl. The available formats are the following: - `csv` – comma-separated values format - `kv` – key-value pairs, one per line diff --git a/doc/_admin-guide/060_Sources/153_stats_exporter/README.md b/doc/_admin-guide/060_Sources/153_stats_exporter/README.md index 86d8d64..484a7a3 100644 --- a/doc/_admin-guide/060_Sources/153_stats_exporter/README.md +++ b/doc/_admin-guide/060_Sources/153_stats_exporter/README.md @@ -53,5 +53,5 @@ log { }; ``` ->**NOTE:** A destination is not required for this to work. The `stats-exporter()` sources will respond to the scraper regardless of whether a destination is present in the log path or not. +>**NOTE:** A destination is not required for this to work. The stats-exporter() sources will respond to the scraper regardless of whether a destination is present in the log path or not. {: .notice--info}