lib/rocket_job/cli.rb in rocketjob-2.0.0 vs lib/rocket_job/cli.rb in rocketjob-2.1.1

- old
+ new

@@ -1,7 +1,6 @@ require 'optparse' -require 'yaml' require 'semantic_logger' module RocketJob # Command Line Interface parser for RocketJob class CLI include SemanticLogger::Loggable @@ -23,25 +22,15 @@ def run Thread.current.name = 'rocketjob main' setup_environment setup_logger rails? ? boot_rails : boot_standalone -# setup_metrics write_pidfile opts = {} opts[:name] = name if name opts[:max_threads] = threads if threads Worker.run(opts) - end - - def setup_metrics - SemanticLogger.on_metric do |log| - if log.metric.start_with?('rocketjob/') - ap log - RocketJob::Stats::ShortTerm.increment_metric(log.time, log.name, log.duration, log.metric_amount) - end - end end def rails? @rails ||= begin boot_file = Pathname.new(directory).join('config/environment.rb').expand_path