File tree 1 file changed +4
-3
lines changed
src/clj/backtype/storm/daemon
1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change 89
89
90
90
(defn read-allocated-workers
91
91
" Returns map from worker id to worker heartbeat. if the heartbeat is nil, then the worker is dead (timed out or never wrote heartbeat)"
92
- [supervisor assigned-tasks]
92
+ [supervisor assigned-tasks now ]
93
93
(let [conf (:conf supervisor)
94
94
^LocalState local-state (:local-state supervisor)
95
- now (current-time-secs )
96
95
id->heartbeat (read-worker-heartbeats conf)
97
96
approved-ids (set (keys (.get local-state LS-APPROVED-WORKERS)))]
98
97
(into
189
188
^LocalState local-state (:local-state supervisor)
190
189
assigned-tasks (defaulted (.get local-state LS-LOCAL-ASSIGNMENTS)
191
190
{})
192
- allocated (read-allocated-workers supervisor assigned-tasks)
191
+ now (current-time-secs )
192
+ allocated (read-allocated-workers supervisor assigned-tasks now)
193
193
keepers (filter-val
194
194
(fn [[state _]] (= state :valid ))
195
195
allocated)
217
217
(when (not= :valid state)
218
218
(log-message
219
219
" Shutting down and clearing state for id " id
220
+ " . Current supervisor time: " now
220
221
" . State: " state
221
222
" , Heartbeat: " (pr-str heartbeat))
222
223
(shutdown-worker supervisor id)
You can’t perform that action at this time.
0 commit comments