chef-metrics 0.0.5 → 1.0.0.alpha

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.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 767e85b7e8ffd89f58eb2234e61ac57d62bd3778
4
+ data.tar.gz: 4af0d5f874da10c2b8454698a5b31f302b96581c
5
+ SHA512:
6
+ metadata.gz: 5514f8322738ba6890865134fcefa83a1af84b3a29035e6f47697a0e76212b77c7d59a08c092be252093d63f741de749494c630b16d615d5cb96163689c7e31e
7
+ data.tar.gz: 4382f422e37738f77d7d1b9a1956a683293e624e01ba6bf5e45e3fe39eec32122b749a9081d241596713a22c3b39b7541c7858ce3cd115d02d917e1a730ae0f8
@@ -1,12 +1,12 @@
1
1
  Gem::Specification.new do |gem|
2
2
  gem.authors = ["Sean Porter"]
3
3
  gem.email = ["portertech@gmail.com"]
4
- gem.description = "OpsCode Chef report handler to send metrics to x"
5
- gem.summary = "OpsCode Chef report handler to send metrics to x"
4
+ gem.description = "Chef report handler to send metrics to x"
5
+ gem.summary = "Chef report handler to send metrics to x"
6
6
  gem.homepage = "https://github.com/portertech/chef-metrics"
7
7
 
8
8
  gem.files = `git ls-files`.split($\)
9
9
  gem.name = "chef-metrics"
10
10
  gem.require_paths = ["lib"]
11
- gem.version = "0.0.5"
11
+ gem.version = "1.0.0.alpha"
12
12
  end
@@ -4,12 +4,12 @@ require "chef/handler"
4
4
  class ChefMetrics < Chef::Handler
5
5
  attr_accessor :metric_scheme, :measure_time, :metrics, :use_run_state, :action
6
6
 
7
- def initialize(&action)
7
+ def initialize(action=nil, &action_block)
8
8
  @metric_scheme = "chef.#{Chef::Config.node_name}"
9
9
  @measure_time = Time.now.to_i
10
10
  @metrics = Hash.new
11
11
  @use_run_state = true
12
- @action = action
12
+ @action = action || action_block
13
13
  end
14
14
 
15
15
  def run_state_metrics!
metadata CHANGED
@@ -1,74 +1,51 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: chef-metrics
3
- version: !ruby/object:Gem::Version
4
- hash: 21
5
- prerelease: false
6
- segments:
7
- - 0
8
- - 0
9
- - 5
10
- version: 0.0.5
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0.alpha
11
5
  platform: ruby
12
- authors:
6
+ authors:
13
7
  - Sean Porter
14
8
  autorequire:
15
9
  bindir: bin
16
10
  cert_chain: []
17
-
18
- date: 2012-11-13 00:00:00 -08:00
19
- default_executable:
11
+ date: 2014-09-17 00:00:00.000000000 Z
20
12
  dependencies: []
21
-
22
- description: OpsCode Chef report handler to send metrics to x
23
- email:
13
+ description: Chef report handler to send metrics to x
14
+ email:
24
15
  - portertech@gmail.com
25
16
  executables: []
26
-
27
17
  extensions: []
28
-
29
18
  extra_rdoc_files: []
30
-
31
- files:
32
- - .gitignore
19
+ files:
20
+ - ".gitignore"
33
21
  - Gemfile
34
22
  - LICENSE
35
23
  - README.md
36
24
  - Rakefile
37
25
  - chef-metrics.gemspec
38
26
  - lib/chef-metrics.rb
39
- has_rdoc: true
40
27
  homepage: https://github.com/portertech/chef-metrics
41
28
  licenses: []
42
-
29
+ metadata: {}
43
30
  post_install_message:
44
31
  rdoc_options: []
45
-
46
- require_paths:
32
+ require_paths:
47
33
  - lib
48
- required_ruby_version: !ruby/object:Gem::Requirement
49
- none: false
50
- requirements:
34
+ required_ruby_version: !ruby/object:Gem::Requirement
35
+ requirements:
51
36
  - - ">="
52
- - !ruby/object:Gem::Version
53
- hash: 3
54
- segments:
55
- - 0
56
- version: "0"
57
- required_rubygems_version: !ruby/object:Gem::Requirement
58
- none: false
59
- requirements:
60
- - - ">="
61
- - !ruby/object:Gem::Version
62
- hash: 3
63
- segments:
64
- - 0
65
- version: "0"
37
+ - !ruby/object:Gem::Version
38
+ version: '0'
39
+ required_rubygems_version: !ruby/object:Gem::Requirement
40
+ requirements:
41
+ - - ">"
42
+ - !ruby/object:Gem::Version
43
+ version: 1.3.1
66
44
  requirements: []
67
-
68
45
  rubyforge_project:
69
- rubygems_version: 1.3.7
46
+ rubygems_version: 2.2.2
70
47
  signing_key:
71
- specification_version: 3
72
- summary: OpsCode Chef report handler to send metrics to x
48
+ specification_version: 4
49
+ summary: Chef report handler to send metrics to x
73
50
  test_files: []
74
-
51
+ has_rdoc: