Skip to content

Instantly share code, notes, and snippets.

@kbarber
Created January 20, 2014 13:39
Show Gist options
  • Select an option

  • Save kbarber/8520011 to your computer and use it in GitHub Desktop.

Select an option

Save kbarber/8520011 to your computer and use it in GitHub Desktop.
diff --git a/puppetdb.rb.bak b/puppetdb.rb
index da36497..1a9a0b4 100644
--- a/puppetdb.rb.bak
+++ b/puppetdb.rb
@@ -7,6 +7,7 @@ class Puppet::Node::Facts::Puppetdb < Puppet::Indirector::REST
include Puppet::Util::Puppetdb::CommandNames
def save(request)
+ Puppet.warning("DEBUG: puppetdb save")
facts = request.instance.dup
facts.values = facts.values.dup
facts.stringify
@@ -16,6 +17,7 @@ class Puppet::Node::Facts::Puppetdb < Puppet::Indirector::REST
end
def find(request)
+ Puppet.warning("DEBUG: puppetdb find")
begin
response = http_get(request, "/v3/nodes/#{CGI.escape(request.key)}/facts", headers)
log_x_deprecation_header(response)
@@ -56,6 +58,7 @@ class Puppet::Node::Facts::Puppetdb < Puppet::Indirector::REST
# `operator` may be one of {eq, ne, lt, gt, le, ge}, and will default to 'eq'
# if unspecified.
def search(request)
+ Puppet.warning("DEBUG: puppetdb search")
return [] unless request.options
operator_map = {
'eq' => '=',
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment