Skip to content
Permalink
Browse files

fix(engine): use current state on cancel processing

  • Loading branch information...
Zelldon committed Jul 10, 2019
1 parent 265667d commit 9413afbc25aeb9ad907f52c12902f8f3fc562576
@@ -37,9 +37,8 @@ public CancelProcessor(JobState state) {
@Override
public void onCommand(TypedRecord<JobRecord> command, CommandControl<JobRecord> commandControl) {
final long jobKey = command.getKey();
final JobRecord job = command.getValue();

if (state.exists(jobKey)) {
final JobRecord job = state.getJob(jobKey);
if (job != null) {
state.cancel(jobKey, job);
commandControl.accept(JobIntent.CANCELED, job);
} else {

0 comments on commit 9413afb

Please sign in to comment.
You can’t perform that action at this time.