Skip to content

Commit

Permalink
Set my_queue_name for MiqProvisionRequests
Browse files Browse the repository at this point in the history
We need to set the queue_name for any ems_operations queue items, this
includes the first one and any requeue_phase calls.
  • Loading branch information
agrare committed Jan 9, 2020
1 parent 3e7bb4f commit 7a114bd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/models/miq_provision_request.rb
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ def my_role(_action = nil)
'ems_operations'
end

def my_queue_name
source.ext_management_system.queue_name_for_ems_operations
end

def requested_task_idx
(1..get_option(:number_of_vms).to_i).to_a
end
Expand Down
1 change: 1 addition & 0 deletions app/models/miq_request_task/state_machine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ def requeue_phase
:deliver_on => 10.seconds.from_now.utc,
:zone => my_zone,
:role => my_role,
:queue_name => my_queue_name,
:tracking_label => tracking_label_id,
:miq_callback => {:class_name => self.class.name, :instance_id => id, :method_name => :execute_callback}
)
Expand Down

0 comments on commit 7a114bd

Please sign in to comment.