Skip to content

Commit

Permalink
fix: markdown: resolve all markdown issues with g-h (influxdata#10172)
Browse files Browse the repository at this point in the history
  • Loading branch information
powersj authored Nov 24, 2021
1 parent 0c02f24 commit 79e479c
Show file tree
Hide file tree
Showing 9 changed files with 65 additions and 64 deletions.
20 changes: 10 additions & 10 deletions plugins/inputs/github/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ Gather repository information from [GitHub][] hosted repositories.
**Note:** Telegraf also contains the [webhook][] input which can be used as an
alternative method for collecting repository information.

### Configuration
## Configuration

```toml
[[inputs.github]]
## List of repositories to monitor
repositories = [
"influxdata/telegraf",
"influxdata/influxdb"
"influxdata/telegraf",
"influxdata/influxdb"
]

## Github API access token. Unauthenticated requests are limited to 60 per hour.
Expand All @@ -25,11 +25,11 @@ alternative method for collecting repository information.
# http_timeout = "5s"

## List of additional fields to query.
## NOTE: Getting those fields might involve issuing additional API-calls, so please
## make sure you do not exceed the rate-limit of GitHub.
##
## Available fields are:
## - pull-requests -- number of open and closed pull requests (2 API-calls per repository)
## NOTE: Getting those fields might involve issuing additional API-calls, so please
## make sure you do not exceed the rate-limit of GitHub.
##
## Available fields are:
## - pull-requests -- number of open and closed pull requests (2 API-calls per repository)
# additional_fields = []
```

Expand All @@ -52,7 +52,7 @@ alternative method for collecting repository information.

When the [internal][] input is enabled:

+ internal_github
- internal_github
- tags:
- access_token - An obfuscated reference to the configured access token or "Unauthenticated"
- fields:
Expand All @@ -72,7 +72,7 @@ In the following we list the available options with the required API-calls and t

### Example Output

```
```shell
github_repository,language=Go,license=MIT\ License,name=telegraf,owner=influxdata forks=2679i,networks=2679i,open_issues=794i,size=23263i,stars=7091i,subscribers=316i,watchers=7091i 1563901372000000000
internal_github,access_token=Unauthenticated closed_pull_requests=3522i,rate_limit_remaining=59i,rate_limit_limit=60i,rate_limit_blocks=0i,open_pull_requests=260i 1552653551000000000
```
Expand Down
11 changes: 6 additions & 5 deletions plugins/inputs/gnmi/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

This plugin consumes telemetry data based on the [gNMI](https://github.com/openconfig/reference/blob/master/rpc/gnmi/gnmi-specification.md) Subscribe method. TLS is supported for authentication and encryption. This input plugin is vendor-agnostic and is supported on any platform that supports the gNMI spec.

For Cisco devices:
It has been optimized to support gNMI telemetry as produced by Cisco IOS XR (64-bit) version 6.5.1, Cisco NX-OS 9.3 and Cisco IOS XE 16.12 and later.
For Cisco devices:

It has been optimized to support gNMI telemetry as produced by Cisco IOS XR (64-bit) version 6.5.1, Cisco NX-OS 9.3 and Cisco IOS XE 16.12 and later.

### Configuration
## Configuration

```toml
[[inputs.gnmi]]
Expand Down Expand Up @@ -66,8 +66,9 @@ It has been optimized to support gNMI telemetry as produced by Cisco IOS XR (64-
# heartbeat_interval = "60s"
```

### Example Output
```
## Example Output

```shell
ifcounters,path=openconfig-interfaces:/interfaces/interface/state/counters,host=linux,name=MgmtEth0/RP0/CPU0/0,source=10.49.234.115 in-multicast-pkts=0i,out-multicast-pkts=0i,out-errors=0i,out-discards=0i,in-broadcast-pkts=0i,out-broadcast-pkts=0i,in-discards=0i,in-unknown-protos=0i,in-errors=0i,out-unicast-pkts=0i,in-octets=0i,out-octets=0i,last-clear="2019-05-22T16:53:21Z",in-unicast-pkts=0i 1559145777425000000
ifcounters,path=openconfig-interfaces:/interfaces/interface/state/counters,host=linux,name=GigabitEthernet0/0/0/0,source=10.49.234.115 out-multicast-pkts=0i,out-broadcast-pkts=0i,in-errors=0i,out-errors=0i,in-discards=0i,out-octets=0i,in-unknown-protos=0i,in-unicast-pkts=0i,in-octets=0i,in-multicast-pkts=0i,in-broadcast-pkts=0i,last-clear="2019-05-22T16:54:50Z",out-unicast-pkts=0i,out-discards=0i 1559145777425000000
```
9 changes: 4 additions & 5 deletions plugins/inputs/graylog/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,14 @@ The Graylog plugin can collect data from remote Graylog service URLs.

Plugin currently support two type of end points:-

- multiple (Ex http://[graylog-server-ip]:12900/system/metrics/multiple)
- namespace (Ex http://[graylog-server-ip]:12900/system/metrics/namespace/{namespace})
- multiple (e.g. `http://[graylog-server-ip]:12900/system/metrics/multiple`)
- namespace (e.g. `http://[graylog-server-ip]:12900/system/metrics/namespace/{namespace}`)

End Point can be a mix of one multiple end point and several namespaces end points


Note: if namespace end point specified metrics array will be ignored for that call.

### Configuration:
## Configuration

```toml
# Read flattened metrics from one or more GrayLog HTTP endpoints
Expand Down Expand Up @@ -52,4 +51,4 @@ Note: if namespace end point specified metrics array will be ignored for that ca
# insecure_skip_verify = false
```

Please refer to GrayLog metrics api browser for full metric end points http://host:12900/api-browser
Please refer to GrayLog metrics api browser for full metric end points `http://host:12900/api-browser`
18 changes: 9 additions & 9 deletions plugins/inputs/haproxy/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ The [HAProxy](http://www.haproxy.org/) input plugin gathers
using the [stats socket](https://cbonte.github.io/haproxy-dconv/1.9/management.html#9.3)
or [HTTP statistics page](https://cbonte.github.io/haproxy-dconv/1.9/management.html#9) of a HAProxy server.

### Configuration:
## Configuration

```toml
# Read metrics of HAProxy, via socket or HTTP stats page
Expand Down Expand Up @@ -40,7 +40,7 @@ or [HTTP statistics page](https://cbonte.github.io/haproxy-dconv/1.9/management.
# insecure_skip_verify = false
```

#### HAProxy Configuration
### HAProxy Configuration

The following information may be useful when getting started, but please
consult the HAProxy documentation for complete and up to date instructions.
Expand All @@ -51,8 +51,7 @@ settings. To enable the unix socket begin by reading about the
[`stats socket`](https://cbonte.github.io/haproxy-dconv/1.8/configuration.html#3.1-stats%20socket)
option.


#### servers
### servers

Server addresses must explicitly start with 'http' if you wish to use HAProxy
status page. Otherwise, addresses will be assumed to be an UNIX socket and
Expand All @@ -65,14 +64,14 @@ To use HTTP Basic Auth add the username and password in the userinfo section
of the URL: `http://user:password@1.2.3.4/haproxy?stats`. The credentials are
sent via the `Authorization` header and not using the request URL.


#### keep_field_names
### keep_field_names

By default, some of the fields are renamed from what haproxy calls them.
Setting the `keep_field_names` parameter to `true` will result in the plugin
keeping the original field names.

The following renames are made:

- `pxname` -> `proxy`
- `svname` -> `sv`
- `act` -> `active_servers`
Expand All @@ -86,7 +85,7 @@ The following renames are made:
- `hrsp_5xx` -> `http_response.5xx`
- `hrsp_other` -> `http_response.other`

### Metrics:
## Metrics

For more details about collected metrics reference the [HAProxy CSV format
documentation](https://cbonte.github.io/haproxy-dconv/1.8/management.html#9.1).
Expand All @@ -110,7 +109,8 @@ documentation](https://cbonte.github.io/haproxy-dconv/1.8/management.html#9.1).
- `lastsess` (int)
- **all other stats** (int)

### Example Output:
```
## Example Output

```shell
haproxy,server=/run/haproxy/admin.sock,proxy=public,sv=FRONTEND,type=frontend http_response.other=0i,req_rate_max=1i,comp_byp=0i,status="OPEN",rate_lim=0i,dses=0i,req_rate=0i,comp_rsp=0i,bout=9287i,comp_in=0i,mode="http",smax=1i,slim=2000i,http_response.1xx=0i,conn_rate=0i,dreq=0i,ereq=0i,iid=2i,rate_max=1i,http_response.2xx=1i,comp_out=0i,intercepted=1i,stot=2i,pid=1i,http_response.5xx=1i,http_response.3xx=0i,http_response.4xx=0i,conn_rate_max=1i,conn_tot=2i,dcon=0i,bin=294i,rate=0i,sid=0i,req_tot=2i,scur=0i,dresp=0i 1513293519000000000
```
9 changes: 4 additions & 5 deletions plugins/inputs/hddtemp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This plugin reads data from hddtemp daemon.

Hddtemp should be installed and its daemon running.

### Configuration
## Configuration

```toml
[[inputs.hddtemp]]
Expand All @@ -19,7 +19,7 @@ Hddtemp should be installed and its daemon running.
# devices = ["sda", "*"]
```

### Metrics
## Metrics

- hddtemp
- tags:
Expand All @@ -31,10 +31,9 @@ Hddtemp should be installed and its daemon running.
- fields:
- temperature

## Example output

### Example output

```
```shell
hddtemp,source=server1,unit=C,status=,device=sdb,model=WDC\ WD740GD-00FLA1 temperature=43i 1481655647000000000
hddtemp,device=sdc,model=SAMSUNG\ HD103UI,unit=C,source=server1,status= temperature=38i 148165564700000000
hddtemp,device=sdd,model=SAMSUNG\ HD103UI,unit=C,source=server1,status= temperature=36i 1481655647000000000
Expand Down
7 changes: 3 additions & 4 deletions plugins/inputs/http/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@

The HTTP input plugin collects metrics from one or more HTTP(S) endpoints. The endpoint should have metrics formatted in one of the supported [input data formats](../../../docs/DATA_FORMATS_INPUT.md). Each data format has its own unique set of configuration options which can be added to the input configuration.


### Configuration:
## Configuration

```toml
# Read formatted metrics from one or more HTTP endpoints
Expand Down Expand Up @@ -73,7 +72,7 @@ The HTTP input plugin collects metrics from one or more HTTP(S) endpoints. The

```

### Metrics:
## Metrics

The metrics collected by this input plugin will depend on the configured `data_format` and the payload returned by the HTTP endpoint(s).

Expand All @@ -83,6 +82,6 @@ The default values below are added if the input format does not specify a value:
- tags:
- url

### Optional Cookie Authentication Settings:
## Optional Cookie Authentication Settings

The optional Cookie Authentication Settings will retrieve a cookie from the given authorization endpoint, and use it in subsequent API requests. This is useful for services that do not provide OAuth or Basic Auth authentication, e.g. the [Tesla Powerwall API](https://www.tesla.com/support/energy/powerwall/own/monitoring-from-home-network), which uses a Cookie Auth Body to retrieve an authorization cookie. The Cookie Auth Renewal interval will renew the authorization by retrieving a new cookie at the given interval.
27 changes: 15 additions & 12 deletions plugins/inputs/http_listener_v2/README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
# HTTP Listener v2 Input Plugin

HTTP Listener v2 is a service input plugin that listens for metrics sent via
HTTP. Metrics may be sent in any supported [data format][data_format]. For metrics in
[InfluxDB Line Protocol][line_protocol] it's recommended to use the [`influxdb_listener`][influxdb_listener]
or [`influxdb_v2_listener`][influxdb_v2_listener] instead.
HTTP. Metrics may be sent in any supported [data format][data_format]. For metrics in
[InfluxDB Line Protocol][line_protocol] it's recommended to use the [`influxdb_listener`][influxdb_listener]
or [`influxdb_v2_listener`][influxdb_v2_listener] instead.

**Note:** The plugin previously known as `http_listener` has been renamed
`influxdb_listener`. If you would like Telegraf to act as a proxy/relay for
InfluxDB it is recommended to use [`influxdb_listener`][influxdb_listener] or [`influxdb_v2_listener`][influxdb_v2_listener].

### Configuration:
## Configuration

This is a sample configuration for the plugin.

Expand Down Expand Up @@ -69,24 +69,27 @@ This is a sample configuration for the plugin.
data_format = "influx"
```

### Metrics:
## Metrics

Metrics are collected from the part of the request specified by the `data_source` param and are parsed depending on the value of `data_format`.

### Troubleshooting:
## Troubleshooting

**Send Line Protocol**
```
Send Line Protocol:

```shell
curl -i -XPOST 'http://localhost:8080/telegraf' --data-binary 'cpu_load_short,host=server01,region=us-west value=0.64 1434055562000000000'
```

**Send JSON**
```
Send JSON:

```shell
curl -i -XPOST 'http://localhost:8080/telegraf' --data-binary '{"value1": 42, "value2": 42}'
```

**Send query params**
```
Send query params:

```shell
curl -i -XGET 'http://localhost:8080/telegraf?host=server01&value=0.42'
```

Expand Down
11 changes: 5 additions & 6 deletions plugins/inputs/http_response/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This input plugin checks HTTP/HTTPS connections.

### Configuration:
## Configuration

```toml
# HTTP/HTTPS request given an address a method and a timeout
Expand Down Expand Up @@ -79,7 +79,7 @@ This input plugin checks HTTP/HTTPS connections.
# interface = "eth0"
```

### Metrics:
## Metrics

- http_response
- tags:
Expand All @@ -96,7 +96,7 @@ This input plugin checks HTTP/HTTPS connections.
- result_type (string, deprecated in 1.6: use `result` tag and `result_code` field)
- result_code (int, [see below](#result--result_code))

#### `result` / `result_code`
### `result` / `result_code`

Upon finishing polling the target server, the plugin registers the result of the operation in the `result` tag, and adds a numeric field called `result_code` corresponding with that tag value.

Expand All @@ -112,9 +112,8 @@ This tag is used to expose network and plugin errors. HTTP errors are considered
|dns_error | 5 |There was a DNS error while attempting to connect to the host|
|response_status_code_mismatch | 6 |The option `response_status_code_match` was used, and the status code of the response didn't match the value.|

## Example Output

### Example Output:

```
```shell
http_response,method=GET,result=success,server=http://github.com,status_code=200 content_length=87878i,http_response_code=200i,response_time=0.937655534,result_code=0i,result_type="success" 1565839598000000000
```
17 changes: 9 additions & 8 deletions plugins/inputs/httpjson/README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# HTTP JSON Input Plugin

### DEPRECATED in Telegraf v1.6: Use [HTTP input plugin](../http) as replacement.
**DEPRECATED in Telegraf v1.6: Use [HTTP input plugin](../http) as replacement**

The httpjson plugin collects data from HTTP URLs which respond with JSON. It flattens the JSON and finds all numeric values, treating them as floats.

### Configuration:
## Configuration

```toml
[[inputs.httpjson]]
Expand Down Expand Up @@ -54,28 +54,28 @@ The httpjson plugin collects data from HTTP URLs which respond with JSON. It fl
# apiVersion = "v1"
```

### Measurements & Fields:
## Measurements & Fields

- httpjson
- response_time (float): Response time in seconds
- response_time (float): Response time in seconds

Additional fields are dependant on the response of the remote service being polled.

### Tags:
## Tags

- All measurements have the following tags:
- server: HTTP origin as defined in configuration as `servers`.
- server: HTTP origin as defined in configuration as `servers`.

Any top level keys listed under `tag_keys` in the configuration are added as tags. Top level keys are defined as keys in the root level of the object in a single object response, or in the root level of each object within an array of objects.


### Examples Output:
## Examples Output

This plugin understands responses containing a single JSON object, or a JSON Array of Objects.

**Object Output:**

Given the following response body:

```json
{
"a": 0.5,
Expand All @@ -87,6 +87,7 @@ Given the following response body:
"service": "service01"
}
```

The following metric is produced:

`httpjson,server=http://localhost:9999/stats/ b_d=0.1,a=0.5,b_e=5,response_time=0.001`
Expand Down

0 comments on commit 79e479c

Please sign in to comment.