Open
Conversation
…n the config file
…le, move config loading functionality into separate functions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Refs #16
Most of the work for this issue is completed. The remaining gap is extending the config file to support metrics (currently only collectors are configurable).
This PR introduces a persistent agent UUID and extends the configuration file with new runtime options.
UUID
A UUID is generated on startup only if the file
agent.uuiddoes not already exist (typically on the first launch).Once created, the UUID is persisted and reused across subsequent restarts.
Currently, the UUID is generated using a custom
GenerateUUIDv4function from theutilsnamespace.In the future, this may be replaced with a dedicated UUID library.
Configuration File
The configuration file has been extended with the following new options:
intervalserver_addressserver_portcollectorsOptions Overview
interval(uint32)Interval between metric collections, in milliseconds.
server_address(string)Central server address (IP address or hostname).
server_port(uint16)Central server port. Must be non-zero.
collectorsSection defining enabled collectors.
Each key contains an array of strings specifying collector backends.
Supported Collectors
cpuproc_statcpu_freqraplzenpowerpmugpunvmldcgmrocmlevel_zerorammem_infovm_statiodisk_statsnet_devNotes
At this stage, only collectors are configurable.
Metrics associated with individual collectors will be exposed and configurable in a future update.