Browse Source

Updated the installer.py script and benchmark_profile file with vert.x 2.0 and added variable cpu count to setup.py

tfb 12 years ago
parent
commit
24128ba901
3 changed files with 8 additions and 5 deletions
  1. 2 1
      config/benchmark_profile
  2. 2 2
      toolset/setup/linux/installer.py
  3. 4 2
      vertx/setup.py

+ 2 - 1
config/benchmark_profile

@@ -1,7 +1,8 @@
 export JAVA_HOME=/usr/lib/jvm/java-1.7.0-openjdk-amd64
 export RESIN_HOME=~/FrameworkBenchmarks/installs/resin-4.0.36
 export GRAILS_HOME=~/FrameworkBenchmarks/installs/grails-2.1.1
-export VERTX_HOME=~/FrameworkBenchmarks/installs/vert.x-1.3.1.final
+#export VERTX_HOME=~/FrameworkBenchmarks/installs/vert.x-1.3.1.final
+export VERTX_HOME=~/FrameworkBenchmarks/installs/vert.x-2.0.0-final
 export GOROOT=~/FrameworkBenchmarks/installs/go
 export GOPATH=~/FrameworkBenchmarks/go:~/FrameworkBenchmarks/webgo:~/FrameworkBenchmarks/revel
 export TOMCAT_HOME=~/FrameworkBenchmarks/installs/apache-tomcat-7.0.35

+ 2 - 2
toolset/setup/linux/installer.py

@@ -283,8 +283,8 @@ class Installer:
     #
     # Vert.x
     #
-    self.__download("http://vertx.io/vertx-downloads/downloads/vert.x-1.3.1.final.tar.gz")
-    self.__run_command("tar xzf vert.x-1.3.1.final.tar.gz")
+    self.__download("http://dl.bintray.com/vertx/downloads/vert.x-2.0.0-final.tar.gz")
+    self.__run_command("tar xzf vert.x-2.0.0-final.tar.gz")
 
     #
     # Yesod

+ 4 - 2
vertx/setup.py

@@ -1,14 +1,16 @@
-
+import multiprocessing
 import subprocess
 import sys
 import setup_util
 import os
 
+nCpu = multiprocessing.cpu_count()
+
 def start(args):
   setup_util.replace_text("vertx/App.groovy", "host: '.*'", "host: '" + args.database_host + "'")
 
   try:    
-    subprocess.Popen("vertx run WebServer.java", shell=True, cwd="vertx")
+    subprocess.Popen("vertx run WebServer.java -instances " + str(nCpu) , shell=True, cwd="vertx")
     return 0
   except subprocess.CalledProcessError:
     return 1