cookbook 'graphite_handler', '~> 0.0.12'
graphite_handler (9) Versions 0.0.12 Follow8
Installs/Configures the Chef graphite handler originally developed by Ian Meyer
cookbook 'graphite_handler', '~> 0.0.12', :supermarket
knife supermarket install graphite_handler
knife supermarket download graphite_handler
Description
A cookbook that includes a report handler for sending chef run results to graphite. If you have
the ohai-system_packages
plugin installed, it will also send package statistics to graphite.
Requirements
The chef_handler
cookbook.
Attributes
This cookbook uses the following attributes to configure how it is installed.
-
node['chef_client']['handler']['graphite']['host']
- The graphite server host. -
node['chef_client']['handler']['graphite']['port']
- The graphite server port. -
node['chef_client']['handler']['graphite']['prefix']
- The prefix appended to statistics sent to graphite. Defaults to"chef.#{node.chef_environment}.node.#{node['hostname']}"
.
Usage
Set the host and port attributes on the node and include the "graphite_handler::default" recipe.
Custom metrics
To send custom metrics, fill a hash in run_context[:graphite_handler_metrics]
.
For instance, in a ruby_block:
run_context[:graphite_handler_metrics] ||= {}
run_context[:graphite_handler_metrics][:monitoring_registration_time] = Benchmark.measure { register node }.real
Credits
The handler was originally written by Ian Meyer and was converted to a cookbook by Peter Donald. Contributions by Lew Goettner, Julian Dunn and others.
Dependent cookbooks
chef_handler >= 0.0.0 |
Contingent cookbooks
There are no cookbooks that are contingent upon this one.
v0.0.12:
- Enhance : Allow custom metrics insertion. Submitted by Grégoire Seux
- Enhance : Allow the user to specify the gem version for graphite gem. Submitted by Olivier Bazoud.
v0.0.10:
- Enhance : Do not specify unix permissions on a windows host.
- Bug : Gracefully handle the presence of a 'system_packages' node attribute without the contained attributes such as 'installed' etc. This will happen when the cookbook is present as a dependency but does not appear in the run list.
- Bug : Correctly handle the scenario where the chef run has failed early enough that the run_status has not been fully defined. Submitted by Scott Smith.
v0.0.8:
- Enhance : Support Ruby 1.8 by including rubygems. Submitted by Julian Dunn.
v0.0.6:
- Enhance : Include ohai-system_packages plugin statistics if available. Submitted by Lew Goettner.
- Change : Change the default prefix to have chef at the front. Submitted by Lew Goettner.
- Change : Change the default prefix to support empty hostname and downcase the hostname.
v0.0.5:
- Bug : Update to use chef_gem for compatibility with omnibus chef installs.
v0.0.4:
- Bug : Stop attempting to print an exception when an error occurs writing to graphite as this can result in an an attempt to render the entire state of the chef context if the exception refers to the context.
v0.0.3:
- Enhance : Improve the error handling when the graphite server is unable to be accessed when the reporter handler executes.
- Bug : Use
Chef::Config[:file_cache_path]}
to determine the cache path rather than hard coding it. - Enhance : Test foodcritic rules using Travis CI.
v0.0.2:
- Enhance : Include the
chef_handler::default
recipe from thegraphite_handler::default
recipe to ensure the required directory has been created.
v0.0.1:
- Initial release.
Collaborator Number Metric
0.0.12 failed this metric
Failure: Cookbook has 0 collaborators. A cookbook must have at least 2 collaborators to pass this metric.
Contributing File Metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file
Foodcritic Metric
0.0.12 failed this metric
FC052: Metadata uses the deprecated "suggests" keyword: graphite_handler/metadata.rb:10
FC064: Ensure issues_url is set in metadata: graphite_handler/metadata.rb:1
FC065: Ensure source_url is set in metadata: graphite_handler/metadata.rb:1
FC066: Ensure chef_version is set in metadata: graphite_handler/metadata.rb:1
FC067: Ensure at least one platform supported in metadata: graphite_handler/metadata.rb:1
FC069: Ensure standardized license defined in metadata: graphite_handler/metadata.rb:1
FC121: Cookbook depends on cookbook made obsolete by Chef 14: graphite_handler/metadata.rb:1
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
No Binaries Metric
0.0.12 passed this metric
Testing File Metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.0.12 failed this metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file
Foodcritic Metric
0.0.12 failed this metric
FC052: Metadata uses the deprecated "suggests" keyword: graphite_handler/metadata.rb:10
FC064: Ensure issues_url is set in metadata: graphite_handler/metadata.rb:1
FC065: Ensure source_url is set in metadata: graphite_handler/metadata.rb:1
FC066: Ensure chef_version is set in metadata: graphite_handler/metadata.rb:1
FC067: Ensure at least one platform supported in metadata: graphite_handler/metadata.rb:1
FC069: Ensure standardized license defined in metadata: graphite_handler/metadata.rb:1
FC121: Cookbook depends on cookbook made obsolete by Chef 14: graphite_handler/metadata.rb:1
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
No Binaries Metric
0.0.12 passed this metric
Testing File Metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.0.12 failed this metric
FC064: Ensure issues_url is set in metadata: graphite_handler/metadata.rb:1
FC065: Ensure source_url is set in metadata: graphite_handler/metadata.rb:1
FC066: Ensure chef_version is set in metadata: graphite_handler/metadata.rb:1
FC067: Ensure at least one platform supported in metadata: graphite_handler/metadata.rb:1
FC069: Ensure standardized license defined in metadata: graphite_handler/metadata.rb:1
FC121: Cookbook depends on cookbook made obsolete by Chef 14: graphite_handler/metadata.rb:1
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
0.0.12 passed this metric
Testing File Metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.0.12 failed this metric
0.0.12 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number