Skip to content

Commit

Permalink
closes #46 (#47)
Browse files Browse the repository at this point in the history
- breaking change: remove hardcoded values when using `--used`. (major vertsion bump)
- appease rubocop
  • Loading branch information
majormoses authored and sstarcher committed Oct 14, 2016
1 parent b1973bb commit 89f4912
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Expand Up @@ -4,8 +4,11 @@ This project adheres to [Semantic Versioning](http://semver.org/).
This CHANGELOG follows the format listed at [Keep A Changelog](http://keepachangelog.com/)

## [Unreleased]

## [2.0.0] - 2016-10-14
### Fixed
- `check-memory-percent.sh`: Corrected units (from MB to %) in performance data output
- `check-ram.rb`: fixed overwriting of cli args for warning and critical when using `--used`

## [1.0.2] - 2016-04-12
### Fixed
Expand Down
2 changes: 0 additions & 2 deletions bin/check-ram.rb
Expand Up @@ -85,8 +85,6 @@ def run
# only free or used should be defined, change defaults to mirror free
if config[:used]
config[:free] = false
config[:warn] = 90
config[:crit] = 95
end

if config[:megabytes]
Expand Down
2 changes: 1 addition & 1 deletion bin/metrics-memory-percent.rb
Expand Up @@ -67,7 +67,7 @@ def metrics_hash
mem['freeWOBuffersCaches'] = mem['free'] + (mem['buffers'] + mem['cached'])

# to prevent division by zero
swptot = if mem['swapTotal'] == 0
swptot = if mem['swapTotal'].zero?
1
else
mem['swapTotal']
Expand Down
4 changes: 2 additions & 2 deletions lib/sensu-plugins-memory-checks/version.rb
@@ -1,8 +1,8 @@
module SensuPluginsMemoryChecks
module Version
MAJOR = 1
MAJOR = 2
MINOR = 0
PATCH = 2
PATCH = 0

VER_STRING = [MAJOR, MINOR, PATCH].compact.join('.')
end
Expand Down

0 comments on commit 89f4912

Please sign in to comment.