Priorityjobscheduler (#3583)

* priority based job execution in java

* minor fixes

* updated to use java 8 features

* fix need for type inference

* handle exception

* indentation

* handling exception generated during terminal of normal flow

* handling exception generated during terminal of normal flow

* added comment
This commit is contained in:
Ganesh
2018-02-11 13:29:30 +05:30
committed by Grzegorz Piwowarek
parent f7e41c7a17
commit d935985ec1
3 changed files with 11 additions and 8 deletions

View File

@@ -30,7 +30,9 @@ public class PriorityJobSchedulerUnitTest {
// delay to avoid job sleep (added for demo) being interrupted
try {
Thread.sleep(2000);
} catch (InterruptedException ignored) {
} catch (InterruptedException e) {
Thread.currentThread().interrupt();
throw new RuntimeException(e);
}
pjs.closeScheduler();