-
Notifications
You must be signed in to change notification settings - Fork 3.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
Statistics and Diagnostics service #3916
Conversation
f0d295d
to
d8588d8
Compare
fd19e5c
to
7527a66
Compare
ec0b5f9
to
d1ff8bc
Compare
@@ -38,6 +38,7 @@ type Config struct { | |||
BindAddress string `toml:"bind-address"` | |||
Database string `toml:"database"` | |||
Enabled bool `toml:"enabled"` | |||
WriteSkip bool `toml:"write-skip"` |
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.
What does this config control/mean?
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.
This allows me to have the Graphite input perform all processing except actually writing to the database. It is tedious to constantly recompile the code, just to check input performance, in isolation. So the idea is a developer can set this flag, and try various other configs (mostly around batching and Goroutines). There have been some complaints about network-level performance and memory usage of Graphite, and I want to be able to test just the Graphite code.
Think of like the way we sometimes processing within the system, but drop the data before writing. It's most convenient if these performance-testing-related switches are configurable. They would not be documented in the sample config however.
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.
It seems odd to have this in the config though since the use case for this is mainly for developers. Won't running influxd config
print it out as the sample config? Usually things like this are enabled using an env var in other systems. e.g. SKIP_WRITES=1 influxd
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.
Hmmm, hadn't though of the sample config. OK, let me nuke it, and deal with it another way (perhaps the environment variable).
Thanks for the valuable feedback @jwilder -- I have responded to some and will update the code. |
5b61e07
to
4e09484
Compare
LGTM 👍 I think the |
4e09484
to
23b6efd
Compare
23b6efd
to
366c011
Compare
Removed |
Got the +1 from @jwilder, so will merge now. |
Statistics and Diagnostics service
This change introduces the new Statistics and Monitor service, and monitors the Graphite input to start. To summarize there is a new component called
monitor
which allow any client that implements a simple interface to register with it. Themonitor
service will then call back to each registered client when statistics or diagnostics are requested via a query.In addition -- though not yet fully implemented -- if enabled (which it is by default) the statistics will be recorded in an InfluxDB system, allowing the full power of InfluxQL to be employed. More details in the associated README file.
Remaining:
Example stats: