From 861c21d1d7de81a68d15be622521891083b7e258 Mon Sep 17 00:00:00 2001 From: Rick Bradley Date: Wed, 3 Oct 2007 12:44:57 -0500 Subject: Added partial spec for the serving of REST information, as well as some client-side REST terminus behavior. --- lib/puppet/indirector/rest.rb | 8 ++++++++ lib/puppet/indirector/rest/node.rb | 6 ++++++ lib/puppet/network/rest_server.rb | 2 ++ 3 files changed, 16 insertions(+) create mode 100644 lib/puppet/indirector/rest.rb create mode 100644 lib/puppet/indirector/rest/node.rb create mode 100644 lib/puppet/network/rest_server.rb (limited to 'lib') diff --git a/lib/puppet/indirector/rest.rb b/lib/puppet/indirector/rest.rb new file mode 100644 index 000000000..8d51aff09 --- /dev/null +++ b/lib/puppet/indirector/rest.rb @@ -0,0 +1,8 @@ +require 'puppet/indirector/rest' + +# Access objects via REST +class Puppet::Indirector::REST < Puppet::Indirector::Terminus + def find(name) + indirection.model.new(name) + end +end diff --git a/lib/puppet/indirector/rest/node.rb b/lib/puppet/indirector/rest/node.rb new file mode 100644 index 000000000..ce809f77a --- /dev/null +++ b/lib/puppet/indirector/rest/node.rb @@ -0,0 +1,6 @@ +require 'puppet/indirector/rest' + +class Puppet::Indirector::REST::Node < Puppet::Indirector::REST + desc "TODO: FIXME" + # TODO/FIXME +end diff --git a/lib/puppet/network/rest_server.rb b/lib/puppet/network/rest_server.rb new file mode 100644 index 000000000..e415e8bcb --- /dev/null +++ b/lib/puppet/network/rest_server.rb @@ -0,0 +1,2 @@ +class Puppet::Network::RESTServer # :nodoc: +end -- cgit From 3f90ddbfc7d20b631ca17f72e2d72d5e7ca00629 Mon Sep 17 00:00:00 2001 From: Rick Bradley Date: Wed, 3 Oct 2007 12:49:23 -0500 Subject: Interpreting "hidden" class from spec drafts as a REST Controller. This name, functionality, and/or location in the tree is subject to change, but it's down now somewhere so we can move forward on it. --- lib/puppet/network/rest_controller.rb | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 lib/puppet/network/rest_controller.rb (limited to 'lib') diff --git a/lib/puppet/network/rest_controller.rb b/lib/puppet/network/rest_controller.rb new file mode 100644 index 000000000..76a9830ea --- /dev/null +++ b/lib/puppet/network/rest_controller.rb @@ -0,0 +1,2 @@ +class Puppet::Network::RESTController # :nodoc: +end -- cgit