aurora-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject aurora git commit: Fixed bug with LocalSchedulerMain not starting up due to missing Modules.
Date Tue, 08 Mar 2016 21:55:24 GMT
Repository: aurora
Updated Branches:
  refs/heads/master 26efe5517 -> a79ce0e64


Fixed bug with LocalSchedulerMain not starting up due to missing Modules.

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


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

Branch: refs/heads/master
Commit: a79ce0e643119f4755af76df1077aa22c897ca16
Parents: 26efe55
Author: Amol Deshmukh <amol@apache.org>
Authored: Tue Mar 8 13:55:12 2016 -0800
Committer: Maxim Khutornenko <maxim@apache.org>
Committed: Tue Mar 8 13:55:12 2016 -0800

----------------------------------------------------------------------
 .../aurora/scheduler/app/local/LocalSchedulerMain.java   | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/aurora/blob/a79ce0e6/src/test/java/org/apache/aurora/scheduler/app/local/LocalSchedulerMain.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/aurora/scheduler/app/local/LocalSchedulerMain.java b/src/test/java/org/apache/aurora/scheduler/app/local/LocalSchedulerMain.java
index fb27657..80fd223 100644
--- a/src/test/java/org/apache/aurora/scheduler/app/local/LocalSchedulerMain.java
+++ b/src/test/java/org/apache/aurora/scheduler/app/local/LocalSchedulerMain.java
@@ -24,8 +24,10 @@ import com.google.common.io.Files;
 import com.google.inject.AbstractModule;
 import com.google.inject.Key;
 import com.google.inject.Module;
+import com.google.inject.TypeLiteral;
 import com.google.inject.util.Modules;
 
+import org.apache.aurora.scheduler.TierModule;
 import org.apache.aurora.scheduler.app.SchedulerMain;
 import org.apache.aurora.scheduler.app.local.simulator.ClusterSimulatorModule;
 import org.apache.aurora.scheduler.mesos.DriverFactory;
@@ -33,6 +35,7 @@ import org.apache.aurora.scheduler.mesos.DriverSettings;
 import org.apache.aurora.scheduler.storage.DistributedSnapshotStore;
 import org.apache.aurora.scheduler.storage.Storage;
 import org.apache.aurora.scheduler.storage.Storage.NonVolatileStorage;
+import org.apache.aurora.scheduler.storage.log.SnapshotStoreImpl;
 import org.apache.mesos.Protos;
 import org.apache.mesos.SchedulerDriver;
 import org.apache.shiro.io.ResourceUtils;
@@ -70,8 +73,6 @@ public final class LocalSchedulerMain {
         .add("-shiro_ini_path="
             + ResourceUtils.CLASSPATH_PREFIX
             + "org/apache/aurora/scheduler/http/api/security/shiro-example.ini")
-        .add("-tier_config="
-            + ResourceUtils.CLASSPATH_PREFIX + "org/apache/aurora/scheduler/tiers.json")
         .add("-enable_h2_console=true")
         .build();
     SchedulerMain.applyStaticArgumentValues(arguments.toArray(new String[] {}));
@@ -79,6 +80,9 @@ public final class LocalSchedulerMain {
     Module persistentStorage = new AbstractModule() {
       @Override
       protected void configure() {
+        bind(new TypeLiteral<Boolean>() { })
+            .annotatedWith(SnapshotStoreImpl.ExperimentalTaskStore.class)
+            .toInstance(false);
         bind(Storage.class).to(Key.get(Storage.class, Storage.Volatile.class));
         bind(NonVolatileStorage.class).to(FakeNonVolatileStorage.class);
         bind(DistributedSnapshotStore.class).toInstance(snapshot -> { });
@@ -96,6 +100,7 @@ public final class LocalSchedulerMain {
       }
     };
 
-    SchedulerMain.flagConfiguredMain(Modules.combine(fakeMesos, persistentStorage));
+    SchedulerMain.flagConfiguredMain(
+        Modules.combine(fakeMesos, persistentStorage, new TierModule()));
   }
 }


Mime
View raw message