Skip to content

Commit

Permalink
Break lease on iteration
Browse files Browse the repository at this point in the history
  • Loading branch information
ndr-brt committed Aug 28, 2023
1 parent 224eaf9 commit dc118f6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -430,6 +430,7 @@ private Boolean checkCompletion(TransferProcess transferProcess) {
var checker = statusCheckerRegistry.resolve(transferProcess.getDataDestination().getType());
if (checker == null) {
monitor.warning(format("No checker found for process %s. The process will not advance to the COMPLETED state.", transferProcess.getId()));
breakLease(transferProcess);
return false;
} else {
var resources = transferProcess.getProvisionedResources();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -606,7 +606,9 @@ void started_shouldNotComplete_whenNoChecker() {
manager.start();

await().untilAsserted(() -> {
verify(transferProcessStore, never()).save(any());
var captor = ArgumentCaptor.forClass(TransferProcess.class);
verify(transferProcessStore).save(captor.capture());
assertThat(captor.getValue().getState()).isEqualTo(STARTED.code());
});
}

Expand Down

0 comments on commit dc118f6

Please sign in to comment.