Skip versioncmp when pe_server_version is missing
This commit updates the version checking logic in puppet_metrics_collector::puppetserver to skip `versioncmp()` when the `pe_server_version` fact is missing. This change allows the class to be applied to FOSS nodes without causing a compilation failure.
Merge pull request #23 from Sharpie/enable-foss-usage
Skip versioncmp when pe_server_version is missing
Remove 127.0.0.1 special case naming
The 127.0.0.1 thing is a hold-over from before we defaulted to smart configuration of metrics collection. It isn't good UX to use that name though. We should remove it from the defaults so that users don't need to know about or be confused by this legacy 127.0.0.1 thing.
Merge pull request #26 from reidmv/127-cleanup
Remove 127.0.0.1 special case naming
Change STDOUT.write to STDOUT.puts
This allows the output to have a proper trailing newline. Otherwise, when processing multiple files there will be a concatenation of the last and first lines of each file
(SLV-653) Add a script for generating system stats
The script is intended to be used as part of an optionial feature to gate system stats the same way other stats are gathered and managed. It uses sar which will poll every x seconds and generate an average, which can then be captured into a file at the same interval as the puppet-metrics-collector polling interval. This keeps the total data down while not missing things that cause short duration spikes (like compiles that last 6 seconds). Initial use will be in performace testing. Had to disable GetText/DecorateString cop for the entire script in the rubocop.yml because inline disables aren't working for some reason. And rubocop is parsing for ruby 2.1 where the fix works, but the same fix doesn't work with later versions of ruby, like the one installed by puppet...
Merge pull request #28 from puppetlabs/SLV-653
(SLV-653) Add a script for generating system stats
Update the system metrics timestamp key
Prior to this commit, the metrics timestamp key name in the output file was `time_stamp_obj`, which caused failures when processing with `json2timeseries.rb` this commit updates the key to be `timestamp` to ensure compatibility with the processing scripts.
Convert system metrics into float
Prior to this commit, the system metrics values were strings. This commit changes them to be floats. This adds compatibility with the existing json2timeseries parsing script as it looks for numeric values.
Merge pull request #31 from jarretlavallee/fix/master/generate_metric…
…s_timestamp Update the system metrics timestamp key
(SLV-672) Add system class to manage system metric
The new system class is very similar to the init.pp... this is to keep the two seperate during development. They may get merged in teh future. But the work flow is such that the master would have puppet metrics collector and sysystem included, while the compilers would only have system. To merge them would require a clean way to turn off all pe metrics for the compilers. Also added system_cpu and system_memory to use sar_metric to gather cpu and memory metrics.
Merge pull request #30 from puppetlabs/SLV-672
(SLV-672) Add system class to manage system metric
Allow for excluding data from the metrics files
Prior to this commit, there was no mechanism for filtering out metrics from the json files. This commit adds filter capabilities and defaults to removing the `pe-puppet-profiler` and `file-sync-storage-service` hashes from the `puppetserver` metrics.
Remove pretty printing from the output
Prior to this commit, the output was pretty printed, which consumes additional disk space. This commit removes the pretty printing to save disk space by elimiating the newline characters.
Add reasonable defaults for excludes
Prior to this commit, the defaults for excludes were not dynamic. This commit adds some defaults based on PE version and sets up a framework for making future changes.
Ensure OSP compatibility with excludes
Prior to this commit, if the `pe_server_version` fact was missing the code would error out. This commit enables OSP and older versions of PE.
Use the hostname instead of IP in the readme
Prior to this commit, the documentation stil specified `127.0.0.1` in the examples. In a previous commit, this was changed to the FQDN of the master and this commit updates the readme to use an example FQDN.
(SLV-688) send script errors to the output file
To be consistent with the rest of puppet metrics collector, and to make the errors more findable. Output them in json format to the output json file. Also trapped the error that would occur if sar wasn't installed SLV-707
Merge pull request #32 from puppetlabs/SLV-688
(SLV-688) send script errors to the output file
Merge pull request #29 from jarretlavallee/feat/master/remove_unused_…
…data Allow for excluding data from the metrics files
Merge pull request #27 from m0dular/aph/trailing-newline
Change STDOUT.write to STDOUT.puts
This commit updates the PDK files from 1.12 to 1.14.1.
This commit updates the release from 5.2.0 to 5.3.0 and updates with CHANGELOG with the changes since the 5.2.0 release.