From 71ecad9904c8c48c023e90e5fbea5b26b180c9cf Mon Sep 17 00:00:00 2001 From: Paul Berry Date: Mon, 29 Nov 2010 11:56:40 -0800 Subject: Maint: Refactor code to use .indirection. Replaced uses of the find, search, destroy, and expire methods on model classes with direct calls to the indirection objects. Also removed the old methods that delegated to the indirection object. --- lib/puppet/network/handler/master.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/puppet/network/handler/master.rb') diff --git a/lib/puppet/network/handler/master.rb b/lib/puppet/network/handler/master.rb index c21aafafc..5b9dd332a 100644 --- a/lib/puppet/network/handler/master.rb +++ b/lib/puppet/network/handler/master.rb @@ -49,7 +49,7 @@ class Puppet::Network::Handler # Pass the facts to the fact handler Puppet::Node::Facts.new(client, facts).save unless local? - catalog = Puppet::Resource::Catalog.find(client) + catalog = Puppet::Resource::Catalog.indirection.find(client) case format when "yaml" -- cgit From 0747b58bfef9c6bb5f1f9ac1eb6a7b3955dac2af Mon Sep 17 00:00:00 2001 From: Paul Berry Date: Tue, 30 Nov 2010 12:06:52 -0800 Subject: Maint: Modified uses of indirector.save to call the indirection directly. This change replaces calls to .save with calls to .indirection.save(). This makes the use of the indirector explicit rather than implicit so that it will be easier to search for all indirector call sites using grep. This is an intermediate refactor on the way towards allowing indirector calls to be explicitly routed to multiple termini. This patch affects production code. --- lib/puppet/network/handler/master.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/puppet/network/handler/master.rb') diff --git a/lib/puppet/network/handler/master.rb b/lib/puppet/network/handler/master.rb index 5b9dd332a..62aab539e 100644 --- a/lib/puppet/network/handler/master.rb +++ b/lib/puppet/network/handler/master.rb @@ -47,7 +47,7 @@ class Puppet::Network::Handler client ||= facts["hostname"] # Pass the facts to the fact handler - Puppet::Node::Facts.new(client, facts).save unless local? + Puppet::Node::Facts.indirection.save(Puppet::Node::Facts.new(client, facts)) unless local? catalog = Puppet::Resource::Catalog.indirection.find(client) -- cgit