class RuboCop::Cop::Chef::Correctness::CookbookUsesNodeSave
Don’t use node.save to save partial node data to the Chef
Infra Server mid-run unless it’s a requirement of cookbook design that can’t be avoided. Node.save can result in failed Chef
Infra runs appearing in search and increases load on the Chef
Infra Server.“
@example
### incorrect node.save
Constants
- MSG
- RESTRICT_ON_SEND
Public Instance Methods
Source
# File lib/rubocop/cop/chef/correctness/node_save.rb, line 37 def on_send(node) node_save?(node) do add_offense(node, severity: :refactor) end end