Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change influxdb port 9999 to 8086 #8198

Merged
merged 3 commits into from
Oct 7, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions docs/CONFIGURATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ INFLUX_PASSWORD="monkey123"
```
For InfluxDB OSS 2:
```
INFLUX_HOST="http://localhost:9999"
INFLUX_HOST="http://localhost:8086" # used to be 9999
INFLUX_TOKEN="replace_with_your_token"
INFLUX_ORG="your_username"
INFLUX_BUCKET="replace_with_your_bucket_name"
Expand Down Expand Up @@ -83,7 +83,7 @@ INFLUX_BUCKET="replace_with_your_bucket_name"
urls = ["${INFLUX_URL}"]
skip_database_creation = ${INFLUX_SKIP_DATABASE_CREATION}
password = "${INFLUX_PASSWORD}"

# For InfluxDB OSS 2:
[[outputs.influxdb_v2]]
urls = ["${INFLUX_HOST}"]
Expand Down Expand Up @@ -112,10 +112,10 @@ parsed:
urls = "http://localhost:8086"
skip_database_creation = true
password = "monkey123"

# For InfluxDB OSS 2:
[[outputs.influxdb_v2]]
urls = ["http://127.0.0.1:9999"]
urls = ["http://127.0.0.1:8086"] # double check the port. could be 9999 if using OSS Beta
token = "replace_with_your_token"
org = "your_username"
bucket = "replace_with_your_bucket_name"
Expand Down Expand Up @@ -499,8 +499,8 @@ patterns is emitted.
The inverse of `tagpass`. If a match is found the metric is discarded. This
is tested on metrics after they have passed the `tagpass` test.

> NOTE: Due to the way TOML is parsed, `tagpass` and `tagdrop` parameters must be
defined at the *_end_* of the plugin definition, otherwise subsequent plugin config
> NOTE: Due to the way TOML is parsed, `tagpass` and `tagdrop` parameters must be
defined at the *_end_* of the plugin definition, otherwise subsequent plugin config
options will be interpreted as part of the tagpass/tagdrop tables.

#### Modifiers
Expand Down
3 changes: 2 additions & 1 deletion plugins/inputs/influxdb_v2_listener/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ defer to the output plugins configuration.
```toml
[[inputs.influxdb_v2_listener]]
## Address and port to host InfluxDB listener on
service_address = ":9999"
## (Double check the port. Could be 9999 if using OSS Beta)
service_address = ":8086"

## Maximum allowed HTTP request body size in bytes.
## 0 means to use the default of 32MiB.
Expand Down
7 changes: 4 additions & 3 deletions plugins/inputs/influxdb_v2_listener/influxdb_v2_listener.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,13 +67,14 @@ type InfluxDBV2Listener struct {

const sampleConfig = `
## Address and port to host InfluxDB listener on
service_address = ":9999"
## (Double check the port. Could be 9999 if using OSS Beta)
service_address = ":8086"

## Maximum allowed HTTP request body size in bytes.
## 0 means to use the default of 32MiB.
# max_body_size = "32MiB"

## Optional tag to determine the bucket.
## Optional tag to determine the bucket.
## If the write has a bucket in the query string then it will be kept in this tag name.
## This tag can be used in downstream outputs.
## The default value of nothing means it will be off and the database will not be recorded.
Expand Down Expand Up @@ -336,7 +337,7 @@ func getPrecisionMultiplier(precision string) time.Duration {
func init() {
inputs.Add("influxdb_v2_listener", func() telegraf.Input {
return &InfluxDBV2Listener{
ServiceAddress: ":9999",
ServiceAddress: ":8086",
timeFunc: time.Now,
}
})
Expand Down
2 changes: 1 addition & 1 deletion plugins/outputs/influxdb_v2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The InfluxDB output plugin writes metrics to the [InfluxDB v2.x] HTTP service.
## Multiple URLs can be specified for a single cluster, only ONE of the
## urls will be written to each interval.
## ex: urls = ["https://us-west-2-1.aws.cloud2.influxdata.com"]
urls = ["http://127.0.0.1:9999"]
urls = ["http://127.0.0.1:8086"]

## Token for authentication.
token = ""
Expand Down
4 changes: 2 additions & 2 deletions plugins/outputs/influxdb_v2/influxdb.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
)

var (
defaultURL = "http://localhost:9999"
defaultURL = "http://localhost:8086"

ErrMissingURL = errors.New("missing URL")
)
Expand All @@ -28,7 +28,7 @@ var sampleConfig = `
## Multiple URLs can be specified for a single cluster, only ONE of the
## urls will be written to each interval.
## ex: urls = ["https://us-west-2-1.aws.cloud2.influxdata.com"]
urls = ["http://127.0.0.1:9999"]
urls = ["http://127.0.0.1:8086"]

## Token for authentication.
token = ""
Expand Down
10 changes: 5 additions & 5 deletions plugins/outputs/influxdb_v2/influxdb_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ func TestDefaultURL(t *testing.T) {
if len(output.URLs) < 1 {
t.Fatal("Default URL failed to get set")
}
require.Equal(t, "http://localhost:9999", output.URLs[0])
require.Equal(t, "http://localhost:8086", output.URLs[0])
}
func TestConnect(t *testing.T) {
tests := []struct {
Expand All @@ -26,7 +26,7 @@ func TestConnect(t *testing.T) {
{
out: influxdb.InfluxDB{
URLs: []string{"http://localhost:1234"},
HTTPProxy: "http://localhost:9999",
HTTPProxy: "http://localhost:8086",
HTTPHeaders: map[string]string{
"x": "y",
},
Expand All @@ -36,7 +36,7 @@ func TestConnect(t *testing.T) {
err: true,
out: influxdb.InfluxDB{
URLs: []string{"!@#$qwert"},
HTTPProxy: "http://localhost:9999",
HTTPProxy: "http://localhost:8086",
HTTPHeaders: map[string]string{
"x": "y",
},
Expand All @@ -56,7 +56,7 @@ func TestConnect(t *testing.T) {
err: true,
out: influxdb.InfluxDB{
URLs: []string{"!@#$%^&*()_+"},
HTTPProxy: "http://localhost:9999",
HTTPProxy: "http://localhost:8086",
HTTPHeaders: map[string]string{
"x": "y",
},
Expand All @@ -66,7 +66,7 @@ func TestConnect(t *testing.T) {
err: true,
out: influxdb.InfluxDB{
URLs: []string{":::@#$qwert"},
HTTPProxy: "http://localhost:9999",
HTTPProxy: "http://localhost:8086",
HTTPHeaders: map[string]string{
"x": "y",
},
Expand Down