Skip to content

Commit

Permalink
The stop is pending, it's not actively stopping
Browse files Browse the repository at this point in the history
https://bugzilla.redhat.com/show_bug.cgi?id=1481800

The worker is probably working on a queue message that takes a long time
so we let it try to complete this work item and have a follow up work
item where we ask the worker to exit cleanly on it's own.  "Stop pending"
better describes this graceful worker exit workflow.

```
** Using session_store: ActionDispatch::Session::MemCacheStore
Checking EVM status...
 Zone    | Server | Status  |            ID |   PID |  SPID | URL                     | Started On           | Last Heartbeat       | Master? | Active Roles
---------+--------+---------+---------------+-------+-------+-------------------------+----------------------+----------------------+---------+-----------------------------------------------------------------------------------------------------------------------------------------------------
 default | EVM    | started | 1000000000001 | 38192 | 38206 | druby://127.0.0.1:50844 | 2017-07-07T21:29:20Z | 2017-07-07T21:32:34Z | true    | automate:database_operations:database_owner:ems_inventory:ems_operations:event:reporting:scheduler:smartstate:user_interface:web_services:websocket

 Worker Type      | Status       |            ID |   PID | SPID  |     Server id | Queue Name / URL    | Started On           | Last Heartbeat       | MB Usage
------------------+--------------+---------------+-------+-------+---------------+---------------------+----------------------+----------------------+----------
 MiqGenericWorker | stop pending | 1000000000207 | 38374 | 38380 | 1000000000001 | generic             | 2017-07-07T21:32:19Z | 2017-07-07T21:32:33Z |      245
 MiqUiWorker      | started      | 1000000000206 | 38234 |       | 1000000000001 | http://0.0.0.0:3000 | 2017-07-07T21:29:21Z | 2017-07-07T21:32:34Z |      533
```
  • Loading branch information
jrafanie committed Aug 15, 2017
1 parent 31c07a1 commit 8388fdf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/tasks/evm_application.rb
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ def self.output_workers_status(servers)
s.miq_workers.order(:type).each do |w|
data <<
[w.type,
w.status,
w.status.sub("stopping", "stop pending"),
w.id,
w.pid,
w.sql_spid,
Expand Down

0 comments on commit 8388fdf

Please sign in to comment.