Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating pe_metric to include additional metrics as per SUP-346 #1

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 22 additions & 1 deletion manifests/pe_metric.pp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,28 @@
'absent' => absent,
},
}

##Ref SUP-346
$additional_metrics = [
{ 'name' => 'compiler.find_node',
'url' => "puppetserver:name=puppetlabs.${::hostname}.compiler.find_node" },
{ 'name' => 'puppetdb.query',
'url' => "puppetserver:name=puppetlabs.${::hostname}.puppetdb.query" },
{ 'name' => 'puppetdb.resource.search',
'url' => "puppetserver:name=puppetlabs.${::hostname}.puppetdb.resource.search" },
{ 'name' => 'puppetdb.facts.encode',
'url' => "puppetserver:name=puppetlabs.${::hostname}.puppetdb.facts.encode" },
{ 'name' => 'puppetdb.command.submit.replace facts',
'url' => "puppetserver:name=puppetlabs.${::hostname}.puppetdb.command.submit.replace facts" },
{ 'name' => 'puppetdb.catalog.munge',
'url' => "puppetserver:name=puppetlabs.${::hostname}.puppetdb.catalog.munge" },
{ 'name' => 'puppetdb.command.submit.replace catalog',
'url' => "puppetserver:name=puppetlabs.${::hostname}.puppetdb.command.submit.replace catalog" },
{ 'name' => 'puppetdb.report.convert_to_wire_format_hash',
'url' => "puppetserver:name=puppetlabs.${::hostname}.puppetdb.report.convert_to_wire_format_hash" },
{ 'name' => 'puppetdb.command.submit.store report',
'url' => "puppetserver:name=puppetlabs.${::hostname}.puppetdb.command.submit.store report" },
]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since these metrics are specific to Puppet Server, the should go over to puppetserver.pp. The pe_metric.pp type is shared by all services, so having them here will apply the collection to PuppetDB and Orchestrator, where these measurements are not present.

The metrics should also be collected only if $::pe_server_version is less than 2018.1.0 as we've added these to the core set reported by the /status endpoint.


$config_hash = {
'hosts' => $hosts.sort(),
'metrics_type' => $metrics_type,
Expand Down