Pools and loadbalancing for resource event actors
[aquarium] / logic / src / main / scala / gr / grnet / aquarium / Main.scala
index 94bf175..dcdd1d7 100644 (file)
@@ -50,17 +50,13 @@ object Main extends Loggable {
 
     MasterConf.MasterConf.startServices()
 
-    addShutdownHook
-
-    logger.info("Started Aquarium")
-  }
-  
-  def addShutdownHook(): Unit = {
     Runtime.getRuntime.addShutdownHook(new Thread(new Runnable {
       def run = {
         logger.info("Shutting down Aquarium")
         MasterConf.MasterConf.stopServices()
       }
     }))
+
+    logger.info("Started Aquarium")
   }
 }
\ No newline at end of file