summaryrefslogtreecommitdiff
path: root/lib/chef/cookbook_version.rb
diff options
context:
space:
mode:
authordanielsdeleo <dan@getchef.com>2015-02-11 12:07:23 -0800
committerdanielsdeleo <dan@getchef.com>2015-02-11 12:07:23 -0800
commitd19fa385eed8f96b5e851d0ffee71c141c5cbe8e (patch)
tree45a50361f4bb7107ea8c096be502c3970cdf10b1 /lib/chef/cookbook_version.rb
parent3544a2a32e8a4ce99a3e39e4a1810578c9773785 (diff)
downloadchef-d19fa385eed8f96b5e851d0ffee71c141c5cbe8e.tar.gz
Remove deprecations for Cookbook Version HTTP resource behaviors
We cannot determine the best way to organize various CookbookManifest formats ahead of time, so we make the CookbookManifest API private, and un-deprecate the methods in CookbookVersion that delegate to CookbookManifest. We'll re-deprecate these when we have a stable public API for CookbookManifest behaviors.
Diffstat (limited to 'lib/chef/cookbook_version.rb')
-rw-r--r--lib/chef/cookbook_version.rb29
1 files changed, 4 insertions, 25 deletions
diff --git a/lib/chef/cookbook_version.rb b/lib/chef/cookbook_version.rb
index 5fa00470d0..c51d5798c5 100644
--- a/lib/chef/cookbook_version.rb
+++ b/lib/chef/cookbook_version.rb
@@ -474,22 +474,12 @@ class Chef
def to_hash
- Chef::Log.deprecation(<<-DEPRECATED)
-Cookbooks now have multiple JSON representations based on the capabilities of the Chef Server.
-To get the Hash representation, use code like `Chef::CookbookManifest.new(cookbook_version).to_hash`
-
-Called from #{caller(1).first}
-DEPRECATED
+ # TODO: this should become deprecated when the API for CookbookManifest becomes stable
cookbook_manifest.to_hash
end
def to_json(*a)
- Chef::Log.deprecation(<<-DEPRECATED)
-Cookbooks now have multiple JSON representations based on the capabilities of the Chef Server.
-To get the JSON representation, use code like `Chef::CookbookManifest.new(cookbook_version).to_json`
-
-Called from #{caller(1).first}
-DEPRECATED
+ # TODO: this should become deprecated when the API for CookbookManifest becomes stable
cookbook_manifest.to_json
end
@@ -513,23 +503,12 @@ DEPRECATED
##
def save_url
- Chef::Log.deprecation(<<-DEPRECATED)
-Cookbooks now have multiple save URLs based on the capabilities of the Chef Server.
-To get the default save URL, use code like `Chef::CookbookManifest.new(cookbook_version).save_url`
-
-Called from #{caller(1).first}
-DEPRECATED
-
+ # TODO: this should become deprecated when the API for CookbookManifest becomes stable
cookbook_manifest.save_url
end
def force_save_url
- Chef::Log.deprecation(<<-DEPRECATED)
-Cookbooks now have multiple save URLs based on the capabilities of the Chef Server.
-To get the default save URL, use code like `Chef::CookbookManifest.new(cookbook_version).force_save_url`
-
-Called from #{caller(1).first}
-DEPRECATED
+ # TODO: this should become deprecated when the API for CookbookManifest becomes stable
cookbook_manifest.force_save_url
end