Class: Deimos::Utils::DbPoller::PollStatus

Inherits:
Struct
  • Object
show all
Defined in:
lib/deimos/utils/db_poller.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#batches_erroredObject

Returns the value of attribute batches_errored

Returns:

  • (Object)

    the current value of batches_errored



41
42
43
# File 'lib/deimos/utils/db_poller.rb', line 41

def batches_errored
  @batches_errored
end

#batches_processedObject

Returns the value of attribute batches_processed

Returns:

  • (Object)

    the current value of batches_processed



41
42
43
# File 'lib/deimos/utils/db_poller.rb', line 41

def batches_processed
  @batches_processed
end

#messages_processedObject

Returns the value of attribute messages_processed

Returns:

  • (Object)

    the current value of messages_processed



41
42
43
# File 'lib/deimos/utils/db_poller.rb', line 41

def messages_processed
  @messages_processed
end

Instance Method Details

#current_batchInteger

Returns:

  • (Integer)


44
45
46
# File 'lib/deimos/utils/db_poller.rb', line 44

def current_batch
  batches_processed + 1
end

#reportString

Returns:

  • (String)


49
50
51
# File 'lib/deimos/utils/db_poller.rb', line 49

def report
  "#{batches_processed} batches, #{batches_errored} errored batches, #{messages_processed} processed messages"
end