lib/qs/route.rb in qs-0.3.0 vs lib/qs/route.rb in qs-0.4.0

- old
+ new

@@ -2,26 +2,26 @@ module Qs class Route - attr_reader :name, :handler_class_name, :handler_class + attr_reader :id, :handler_class_name, :handler_class - def initialize(name, handler_class_name) - @name = name.to_s + def initialize(route_id, handler_class_name) + @id = route_id.to_s @handler_class_name = handler_class_name @handler_class = nil end def validate! @handler_class = constantize_handler_class(@handler_class_name) end - def run(job, daemon_data) + def run(message, daemon_data) QsRunner.new(self.handler_class, { - :job => job, - :params => job.params, - :logger => daemon_data.logger + :message => message, + :params => message.params, + :logger => daemon_data.logger }).run end private