-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Add tengine inputs #4160
Add tengine inputs #4160
Conversation
.idea/vcs.xml
Outdated
@@ -0,0 +1,6 @@ | |||
<?xml version="1.0" encoding="UTF-8"?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this file
plugins/inputs/tengine/tengine.go
Outdated
if err != nil { | ||
return err | ||
} | ||
tenginestatus.bytes_in, err = strconv.ParseUint(line_split[1], 10, 64) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We probably need to fix this in the nginx plugin, but ensure that the line is split as expected by checking the length first.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I have fixed it
tenginestatus.http_ups_5xx, err = strconv.ParseUint(line_split[29], 10, 64) | ||
if err != nil { | ||
return err | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Optional: maybe we can use encoding/csv
from the standard library for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fell that is not need to use csv
plugins/inputs/tengine/tengine.go
Outdated
} | ||
|
||
func (n *Tengine) Description() string { | ||
return "Read Nginx's basic status information (ngx_http_stub_status_module)" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update for the new plugin
plugins/inputs/tengine/tengine.go
Outdated
|
||
var sampleConfig = ` | ||
# An array of Nginx stub_status URI to gather stats. | ||
urls = ["http://localhost/server_status"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should use "http://127.0.0.1/us"
as the default since it matches the example here and may help confusion with ngx_http_stub_status_module
This is not successful that let me not understand. |
.gitignore
Outdated
@@ -2,3 +2,4 @@ | |||
/telegraf | |||
/telegraf.exe | |||
/telegraf.gz | |||
/.idea |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this, but you can put it in your global excludes file. If you don't have one just do something like this:
git config --global core.excludesfile /home/ertaoxu/.gitignore
cat "/.idea" >> /home/ertaoxu/.gitignore
@ertaoxu To fix the formatting test failure you just need to run |
Done. Thank you. |
This reverts commit 697d8ce.
@ertaoxu Can you sign the CLA? This is the only thing we need before merging (in the meantime I reverted this PR since I accidentally merged it to soon). |
@ertaoxu The deadline for 1.7 is end of month, any chance you have been able to review the CLA? Hoping to include this plugin! |
Sorry, a bit late. |
@ertaoxu I see you signed the CLA, but your github username doesn't quite match. Could you sign it again and make sure to use |
@danielnelson I have done what you said and thank you for your patience and help. |
This reverts commit 8826cdc.
I have added the plugin back to master but we did miss the window for 1.7 so it will need to be included in 1.8. Thanks for the great contribution! |
* master: (329 commits) Fix panic with unicode counter names in win_perf_counters (influxdata#4255) Update go-syslog version Update changelog Update tengine docs Restore tengine input plugin (influxdata#4160) Fix TLS and SSL config option parsing (influxdata#4247) Update changelog Use same flags for all bsd family ping varients (influxdata#4241) Ignore more boring filesystems from disk plugin (influxdata#4244) Update changelog Add SSL/TLS support to Redis input (influxdata#4236) Don't skip metrics during startup in aggregate phase (influxdata#4230) Set 1.6.4 release date Update master version to 1.8 Update sample config Add go-syslog to dependencies licenses list Update changelog Revert "Update aerospike-client-go version to latest release (influxdata#4128)" Update changelog Fix misnamed option in varnish sample config ...
This reverts commit 8826cdc.
This reverts commit 697d8ce.
This reverts commit 8826cdc.
Required for all PRs: