class Rudy::Routines::Passthrough
Public Instance Methods
execute()
click to toggle source
# File lib/rudy/routines/passthrough.rb, line 16 def execute Rudy::Routines::Handlers::Depends.execute_all @before, @argv li " Executing routine: #{@name} ".att(:reverse), "" # Re-retreive the machine set to reflect dependency changes Rudy::Routines.rescue { @machines = Rudy::Machines.list || [] @@rset = Rudy::Routines::Handlers::RyeTools.create_set @machines } return @machines unless run? Rudy::Routines.runner(@routine, @@rset, @@lbox, @argv) Rudy::Routines::Handlers::Depends.execute_all @after, @argv @machines end
init(*args)
click to toggle source
# File lib/rudy/routines/passthrough.rb, line 9 def init(*args) Rudy::Routines.rescue { @machines = Rudy::Machines.list || [] @@rset = Rudy::Routines::Handlers::RyeTools.create_set @machines } end
raise_early_exceptions()
click to toggle source
Called by generic_machine_runner
# File lib/rudy/routines/passthrough.rb, line 32 def raise_early_exceptions raise Rudy::Error, "No routine name" unless @name raise NoRoutine, @name unless @routine ##raise MachineGroupNotDefined, current_machine_group unless known_machine_group? # Call raise_early_exceptions for each handler used in the routine @routine.each_pair do |action,definition| raise NoHandler, action unless Rudy::Routines.has_handler?(action) handler = Rudy::Routines.get_handler action handler.raise_early_exceptions(action, definition, @@rset, @@lbox, @argv) end end