sensu-plugins-postgres 1.1.2 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9d26dcdd44fe98c05713721dc06ad27d57f8355c
4
- data.tar.gz: 16854ca670b8a788df78361545dc54f7dfc740bf
3
+ metadata.gz: 3fcb3f51d636da304f46576f3c853bd2ef950f94
4
+ data.tar.gz: 125a321c2baeb687ae0ef3be75082638e8846abb
5
5
  SHA512:
6
- metadata.gz: b417867bf2dc052bf32b3fc3b826a2c722cd08ff21f01d2065bc1cbd2a150ff0291b1b53aa7e1d40c5e40b2114b15f0fb262ce8989d88667b776b35de285d4ea
7
- data.tar.gz: 22cc054c1cc75465c71d22664c07dc4903b040eb158092d6c15a87fb6b7d8e122c19eae55f3120c1cd6453ce959c559c959c9b23e096b01c2776b5105f6f9a95
6
+ metadata.gz: 20c55fc65593d0c481feb05546f9f4fb7e32a609382ce3bea8ccf4f946a171f40c6a89491c07bfad19596873e696d9d0657e43421025e954ac8efd83a20e88cf
7
+ data.tar.gz: 857db156200127bc186d9b6295a20afdb1883ba13d87c273b23a425d565f51c53a4f574244dd138b70cf479aa3b3240f5f9e3d24d842887b6b135ba04b240f92
data/CHANGELOG.md CHANGED
@@ -4,6 +4,9 @@ This project adheres to [Semantic Versioning](http://semver.org/).
4
4
  This CHANGELOG follows the format listed at [Keep A Changelog](http://keepachangelog.com/)
5
5
 
6
6
  ## [Unreleased]
7
+ ## [1.2.0] - 2017-07-12
8
+ ### Added
9
+ - metric-postgres-statsdb.rb: Adds new metric `numbackends`. (@phumpal)
7
10
 
8
11
  ## [1.1.2] - 2017-06-02
9
12
  ### Fixed
@@ -95,7 +98,8 @@ This CHANGELOG follows the format listed at [Keep A Changelog](http://keepachang
95
98
  ### Added
96
99
  - initial release
97
100
 
98
- [Unreleased]: https://github.com/sensu-plugins/sensu-plugins-postgres/compare/1.1.2...HEAD
101
+ [Unreleased]: https://github.com/sensu-plugins/sensu-plugins-postgres/compare/1.2.0...HEAD
102
+ [1.2.0]: https://github.com/sensu-plugins/sensu-plugins-postgres/compare/1.1.2...1.2.0
99
103
  [1.1.2]: https://github.com/sensu-plugins/sensu-plugins-postgres/compare/1.1.1...1.1.2
100
104
  [1.1.1]: https://github.com/sensu-plugins/sensu-plugins-postgres/compare/1.1.0...1.1.1
101
105
  [1.1.0]: https://github.com/sensu-plugins/sensu-plugins-postgres/compare/1.0.1...1.1.0
@@ -83,13 +83,14 @@ class PostgresStatsDBMetrics < Sensu::Plugin::Metric::CLI::Graphite
83
83
  port: config[:port],
84
84
  connect_timeout: config[:timeout])
85
85
  request = [
86
- 'select xact_commit, xact_rollback,',
86
+ 'select numbackends, xact_commit, xact_rollback,',
87
87
  'blks_read, blks_hit,',
88
88
  'tup_returned, tup_fetched, tup_inserted, tup_updated, tup_deleted',
89
89
  "from pg_stat_database where datname='#{config[:database]}'"
90
90
  ]
91
91
  con.exec(request.join(' ')) do |result|
92
92
  result.each do |row|
93
+ output "#{config[:scheme]}.statsdb.#{config[:database]}.numbackends", row['numbackends'], timestamp
93
94
  output "#{config[:scheme]}.statsdb.#{config[:database]}.xact_commit", row['xact_commit'], timestamp
94
95
  output "#{config[:scheme]}.statsdb.#{config[:database]}.xact_rollback", row['xact_rollback'], timestamp
95
96
  output "#{config[:scheme]}.statsdb.#{config[:database]}.blks_read", row['blks_read'], timestamp
@@ -1,8 +1,8 @@
1
1
  module SensuPluginsPostgres
2
2
  module Version
3
3
  MAJOR = 1
4
- MINOR = 1
5
- PATCH = 2
4
+ MINOR = 2
5
+ PATCH = 0
6
6
 
7
7
  VER_STRING = [MAJOR, MINOR, PATCH].compact.join('.')
8
8
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sensu-plugins-postgres
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sensu-Plugins and contributors
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-06-02 00:00:00.000000000 Z
11
+ date: 2017-07-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sensu-plugin