Class: LogBrew::WorkerDeliveryFailure

Inherits:
Object
  • Object
show all
Defined in:
lib/logbrew/worker_lifecycle.rb

Overview

Content-free delivery details safe for application-owned diagnostics.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(stage:, code:, pending_events:, pending_event_bytes:, dropped_events:) ⇒ WorkerDeliveryFailure

Returns a new instance of WorkerDeliveryFailure.



8
9
10
11
12
13
14
15
# File 'lib/logbrew/worker_lifecycle.rb', line 8

def initialize(stage:, code:, pending_events:, pending_event_bytes:, dropped_events:)
  @stage = stage.dup.freeze
  @code = code.dup.freeze
  @pending_events = pending_events
  @pending_event_bytes = pending_event_bytes
  @dropped_events = dropped_events
  freeze
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



6
7
8
# File 'lib/logbrew/worker_lifecycle.rb', line 6

def code
  @code
end

#dropped_eventsObject (readonly)

Returns the value of attribute dropped_events.



6
7
8
# File 'lib/logbrew/worker_lifecycle.rb', line 6

def dropped_events
  @dropped_events
end

#pending_event_bytesObject (readonly)

Returns the value of attribute pending_event_bytes.



6
7
8
# File 'lib/logbrew/worker_lifecycle.rb', line 6

def pending_event_bytes
  @pending_event_bytes
end

#pending_eventsObject (readonly)

Returns the value of attribute pending_events.



6
7
8
# File 'lib/logbrew/worker_lifecycle.rb', line 6

def pending_events
  @pending_events
end

#stageObject (readonly)

Returns the value of attribute stage.



6
7
8
# File 'lib/logbrew/worker_lifecycle.rb', line 6

def stage
  @stage
end