class DbSucker::Application::SklavenTreiber::Worker
Constants
- ChannelFailRetryError
- SlotPoolNotInitializedError
- UnknownFileTransportError
Attributes
ctn[R]
exception[R]
monitor[R]
perform[R]
should_cancel[R]
sklaventreiber[R]
sshing[R]
step[R]
table[R]
thread[R]
timings[R]
var[R]
Public Class Methods
new(sklaventreiber, ctn, var, table)
click to toggle source
# File lib/db_sucker/application/sklaven_treiber/worker.rb, line 17 def initialize sklaventreiber, ctn, var, table @sklaventreiber = sklaventreiber @ctn = ctn @var = var @table = table @monitor = Monitor.new @timings = {} @deferred = false @spinner_frames = sklaventreiber.window.try(:spinner_frames).try(:dup) || [] @current_perform = :unknown @perform = %w[].tap do |perform| perform << "r_dump_file" perform << "r_calculate_raw_hash" if ctn.integrity? perform << "r_compress_file" perform << "r_calculate_compressed_hash" if ctn.integrity? perform << "l_download_file" perform << "l_verify_compressed_hash" if ctn.integrity? perform << "l_copy_file" if var.copies_file? && var.copies_file_compressed? if var.requires_uncompression? perform << "l_decompress_file" perform << "l_verify_raw_hash" if ctn.integrity? perform << "l_copy_file" if var.copies_file? && !var.copies_file_compressed? perform << "l_import_file" if var.data["database"] end end @state = :pending @status = ["waiting...", "gray"] end