def run_action(action=nil)
@action = action unless action.nil?
if !whyrun_mode? || whyrun_supported?
load_current_resource
events.resource_current_state_loaded(@new_resource, @action, @current_resource)
elsif whyrun_mode? && !whyrun_supported?
events.resource_current_state_load_bypassed(@new_resource, @action, @current_resource)
end
define_resource_requirements
process_resource_requirements
if whyrun_supported? && !requirements.action_blocked?(@action)
send("action_#{@action}")
elsif whyrun_mode?
events.resource_bypassed(@new_resource, @action, self)
else
send("action_#{@action}")
end
set_updated_status
cleanup_after_converge
end