aurora-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kevi...@apache.org
Subject [2/2] git commit: Shutdown cron asynchronously
Date Wed, 16 Apr 2014 20:33:15 GMT
Shutdown cron asynchronously

Testing Done:
./gradlew build

Bugs closed: AURORA-325

Reviewed at https://reviews.apache.org/r/20425/


Project: http://git-wip-us.apache.org/repos/asf/incubator-aurora/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-aurora/commit/e86bf3de
Tree: http://git-wip-us.apache.org/repos/asf/incubator-aurora/tree/e86bf3de
Diff: http://git-wip-us.apache.org/repos/asf/incubator-aurora/diff/e86bf3de

Branch: refs/heads/kts/AURORA-325-hotfix
Commit: e86bf3ded295c754147f7822e45d3f7dc4decaf8
Parents: 568ac59
Author: Kevin Sweeney <kevints@apache.org>
Authored: Wed Apr 16 13:19:15 2014 -0700
Committer: Kevin Sweeney <kevints@apache.org>
Committed: Wed Apr 16 13:30:02 2014 -0700

----------------------------------------------------------------------
 .../java/org/apache/aurora/scheduler/state/CronJobManager.java   | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/e86bf3de/src/main/java/org/apache/aurora/scheduler/state/CronJobManager.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/aurora/scheduler/state/CronJobManager.java b/src/main/java/org/apache/aurora/scheduler/state/CronJobManager.java
index fa39e2b..4bd190c 100644
--- a/src/main/java/org/apache/aurora/scheduler/state/CronJobManager.java
+++ b/src/main/java/org/apache/aurora/scheduler/state/CronJobManager.java
@@ -172,7 +172,9 @@ public class CronJobManager implements EventSubscriber {
     shutdownRegistry.addAction(new Command() {
       @Override
       public void execute() {
-        cron.stopAsync().awaitTerminated();
+        // NOTE: We don't know ahead-of-time which thread will execute the shutdown command,
+        // so we shouldn't block here.
+        cron.stopAsync();
       }
     });
 


Mime
View raw message