Sha256: f148d0c55748ef756ad5d222effef666df83b71f641ecc36882b37ce5e1c564b

Contents?: true

Size: 509 Bytes

Versions: 6

Compression:

Stored size: 509 Bytes

Contents

module Process::Naf
  class LogArchiverQueuer < ::Process::Naf::Application

    def work
      # Archive logs
      params = { command: log_archiver.command }
      boss.enqueue_n_commands_on_machines(params, :from_limit, machines)
    end

    private

    def boss
      ::Logical::Naf::ConstructionZone::Boss.new
    end

    def machines
      ::Naf::Machine.enabled.up.all
    end

    def log_archiver
      ::Naf::Application.where(command: '::Process::Naf::LogArchiver.run').first
    end

  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
naf-2.1.13 app/models/process/naf/log_archiver_queuer.rb
naf-2.1.12 app/models/process/naf/log_archiver_queuer.rb
naf-2.1.11 app/models/process/naf/log_archiver_queuer.rb
naf-2.1.10 app/models/process/naf/log_archiver_queuer.rb
naf-2.1.9 app/models/process/naf/log_archiver_queuer.rb
naf-2.1.8 app/models/process/naf/log_archiver_queuer.rb