Skip to content

Commit

Permalink
Merge pull request #23175 from liu-samuel/allow-time-param-requeue
Browse files Browse the repository at this point in the history
Change requeue_phase to have params passed in for time with default value of 10
  • Loading branch information
agrare committed Sep 6, 2024
2 parents 34335f9 + 212fa04 commit 7babb13
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/models/miq_request_task/state_machine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,14 @@ def prematurely_finished?
false
end

def requeue_phase
def requeue_phase(delay = 10.seconds)
mark_execution_servers
save # Save current phase_context
MiqQueue.put(
:class_name => self.class.name,
:instance_id => id,
:method_name => phase,
:deliver_on => 10.seconds.from_now.utc,
:deliver_on => delay.from_now.utc,
:zone => my_zone,
:role => my_role,
:queue_name => my_queue_name,
Expand Down

0 comments on commit 7babb13

Please sign in to comment.