Fix #5461, actually stop a job from the RPC service
Fix #5461. The RPC service is incorrectly using the wrong method to stop a job, this patch should fix that.bug/bundler_fix
parent
26785b34f1
commit
910ae8a480
|
@ -28,9 +28,10 @@ class RPC_Job < RPC_Base
|
|||
# @example Here's how you would use this from the client:
|
||||
# rpc.call('job.stop', 0)
|
||||
def rpc_stop(jid)
|
||||
obj = self.framework.jobs[jid.to_s]
|
||||
jid = jid.to_s
|
||||
obj = self.framework.jobs[jid]
|
||||
error(500, "Invalid Job") if not obj
|
||||
obj.stop
|
||||
self.framework.jobs.stop_job(jid)
|
||||
{ "result" => "success" }
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue