Skip to content

Commit

Permalink
refactor(http_listener_v2): set empty string as default path
Browse files Browse the repository at this point in the history
Signed-off-by: Dominik Rosiek <drosiek@sumologic.com>
  • Loading branch information
Dominik Rosiek committed Jul 23, 2021
1 parent 2a3ef57 commit d6b440d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion plugins/inputs/http_listener_v2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ This is a sample configuration for the plugin.

## Path to listen to.
## This option is deprecated and only available for backward-compatibility. Please use paths instead.
# path = "/telegraf"
# path = ""

## Paths to listen to.
# paths = ["/telegraf"]
Expand Down
3 changes: 1 addition & 2 deletions plugins/inputs/http_listener_v2/http_listener_v2.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ const sampleConfig = `
## Path to listen to.
## This option is deprecated and only available for backward-compatibility. Please use paths instead.
# path = "/telegraf"
# path = ""
## Paths to listen to.
# paths = ["/telegraf"]
Expand Down Expand Up @@ -390,7 +390,6 @@ func init() {
return &HTTPListenerV2{
ServiceAddress: ":8080",
TimeFunc: time.Now,
Path: "/telegraf",
Paths: []string{"/telegraf"},
Methods: []string{"POST", "PUT"},
DataSource: body,
Expand Down

0 comments on commit d6b440d

Please sign in to comment.