Skip to content

Commit

Permalink
Remove dead link from logparser sampleconfig and fix syntax (influxda…
Browse files Browse the repository at this point in the history
  • Loading branch information
danielnelson authored and otherpirate committed Mar 15, 2019
1 parent 2df50d7 commit 91992e8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions plugins/inputs/logparser/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ regex patterns.
### Configuration:

```toml
# Stream and parse log file(s).
[[inputs.logparser]]
## Log files to parse.
## These accept standard unix glob matching rules, but with the addition of
Expand All @@ -25,7 +26,6 @@ regex patterns.
# watch_method = "inotify"

## Parse logstash-style "grok" patterns:
## Telegraf built-in parsing patterns: https://goo.gl/dkay10
[inputs.logparser.grok]
## This is a list of patterns to check the given log file(s) for.
## Note that adding patterns here increases processing time. The most
Expand Down Expand Up @@ -54,7 +54,7 @@ regex patterns.
## 1. Local -- interpret based on machine localtime
## 2. "Canada/Eastern" -- Unix TZ values like those found in https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
## 3. UTC -- or blank/unspecified, will return timestamp in UTC
timezone = "Canada/Eastern"
# timezone = "Canada/Eastern"
```

### Grok Parser
Expand Down
4 changes: 2 additions & 2 deletions plugins/inputs/logparser/logparser.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ const sampleConfig = `
## Custom patterns can also be defined here. Put one pattern per line.
custom_patterns = '''
'''
## Timezone allows you to provide an override for timestamps that
## don't already include an offset
Expand All @@ -98,8 +99,7 @@ const sampleConfig = `
## 1. Local -- interpret based on machine localtime
## 2. "Canada/Eastern" -- Unix TZ values like those found in https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
## 3. UTC -- or blank/unspecified, will return timestamp in UTC
timezone = "Canada/Eastern"
'''
# timezone = "Canada/Eastern"
`

// SampleConfig returns the sample configuration for the plugin
Expand Down

0 comments on commit 91992e8

Please sign in to comment.