Browse Source

go: edit benchmark_config and add setup_prefork.sh

Sokolov Yura aka funny_falcon 10 years ago
parent
commit
bca0bb1f8d
2 changed files with 33 additions and 0 deletions
  1. 23 0
      frameworks/Go/go/benchmark_config
  2. 10 0
      frameworks/Go/go/setup_prefork.sh

+ 23 - 0
frameworks/Go/go/benchmark_config

@@ -23,6 +23,29 @@
       "display_name": "go",
       "notes": "",
       "versus": "go"
+    },
+    "prefork": {
+      "setup_file": "setup_prefork",
+      "json_url": "/json",
+      "db_url": "/db",
+      "query_url": "/queries?queries=",
+      "fortune_url": "/fortune",
+      "update_url": "/update?queries=",
+      "plaintext_url": "/plaintext",
+      "port": 8080,
+      "approach": "Realistic",
+      "classification": "Platform",
+      "database": "MySQL",
+      "framework": "go",
+      "language": "Go",
+      "orm": "Raw",
+      "platform": "Go",
+      "webserver": "None",
+      "os": "Linux",
+      "database_os": "Linux",
+      "display_name": "go",
+      "notes": "",
+      "versus": "go"
     }
   }]
 }

+ 10 - 0
frameworks/Go/go/setup_prefork.sh

@@ -0,0 +1,10 @@
+#!/bin/bash
+
+sed -i 's|tcp(.*:3306)|tcp('"${DBHOST}"':3306)|g' src/hello/hello.go
+
+# Where to find the go executable
+export PATH="$GOROOT/bin:$PATH"
+
+go get ./...
+
+go run src/hello/hello.go -prefork &