Class: River::Driver::JobInsertParams

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

Overview

Insert parameters for a job. This is sent to underlying drivers and is meant for internal use only. Its interface is subject to change.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(encoded_args:, kind:, max_attempts:, priority:, queue:, scheduled_at:, state:, tags:, unique_key: nil, unique_states: nil) ⇒ JobInsertParams

Returns a new instance of JobInsertParams.



21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# File 'lib/driver.rb', line 21

def initialize(
  encoded_args:,
  kind:,
  max_attempts:,
  priority:,
  queue:,
  scheduled_at:,
  state:,
  tags:,
  unique_key: nil,
  unique_states: nil
)
  self.encoded_args = encoded_args
  self.kind = kind
  self.max_attempts = max_attempts
  self.priority = priority
  self.queue = queue
  self.scheduled_at = scheduled_at
  self.state = state
  self.tags = tags
  self.unique_key = unique_key
  self.unique_states = unique_states
end

Instance Attribute Details

#encoded_argsObject

Returns the value of attribute encoded_args.



10
11
12
# File 'lib/driver.rb', line 10

def encoded_args
  @encoded_args
end

#kindObject

Returns the value of attribute kind.



11
12
13
# File 'lib/driver.rb', line 11

def kind
  @kind
end

#max_attemptsObject

Returns the value of attribute max_attempts.



12
13
14
# File 'lib/driver.rb', line 12

def max_attempts
  @max_attempts
end

#priorityObject

Returns the value of attribute priority.



13
14
15
# File 'lib/driver.rb', line 13

def priority
  @priority
end

#queueObject

Returns the value of attribute queue.



14
15
16
# File 'lib/driver.rb', line 14

def queue
  @queue
end

#scheduled_atObject

Returns the value of attribute scheduled_at.



15
16
17
# File 'lib/driver.rb', line 15

def scheduled_at
  @scheduled_at
end

#stateObject

Returns the value of attribute state.



16
17
18
# File 'lib/driver.rb', line 16

def state
  @state
end

#tagsObject

Returns the value of attribute tags.



17
18
19
# File 'lib/driver.rb', line 17

def tags
  @tags
end

#unique_keyObject

Returns the value of attribute unique_key.



18
19
20
# File 'lib/driver.rb', line 18

def unique_key
  @unique_key
end

#unique_statesObject

Returns the value of attribute unique_states.



19
20
21
# File 'lib/driver.rb', line 19

def unique_states
  @unique_states
end