Browse Source

Improvements for servlet, json, db. Will hopefully run on EC2 now.

weltermann17 11 years ago
parent
commit
b8cebd7127

+ 3 - 26
plain/benchmark_config

@@ -9,7 +9,7 @@
       "query_url": "/db?queries=",
       "update_url": "/update?queries=",
       "fortune_url": "/fortunes",
-      "port": 9080,
+      "port": 8080,
       "approach": "Realistic",
       "classification": "Fullstack",
       "database": "MySQL",
@@ -32,7 +32,7 @@
       "query_url": "/web-apps/servlet/db?queries=",
       "update_url": "/web-apps/servlet/update?queries=",
       "fortune_url": "/web-apps/servlet/fortunes",
-      "port": 9080,
+      "port": 8080,
       "approach": "Realistic",
       "classification": "Fullstack",
       "database": "MySQL",
@@ -55,7 +55,7 @@
       "query_url": "/db?queries=",
       "update_url": "/update?queries=",
       "fortune_url": "/fortunes",
-      "port": 9080,
+      "port": 8080,
       "approach": "Realistic",
       "classification": "Fullstack",
       "database": "MySQL",
@@ -69,29 +69,6 @@
       "display_name": "plain-windows",
       "notes": "",
       "versus": ""
-    },
-    "win-servlet": {
-      "setup_file": "setup",
-      "json_url": "/web-apps/servlet/json",
-      "plaintext_url": "/web-apps/servlet/plaintext",
-      "db_url": "/web-apps/servlet/db",
-      "query_url": "/web-apps/servlet/db?queries=",
-      "update_url": "/web-apps/servlet/update?queries=",
-      "fortune_url": "/web-apps/servlet/fortunes",
-      "port": 9080,
-      "approach": "Realistic",
-      "classification": "Fullstack",
-      "database": "MySQL",
-      "framework": "plain",
-      "language": "Scala",
-      "orm": "Full",
-      "platform": "Plain",
-      "webserver": "None",
-      "os": "Windows",
-      "database_os": "Linux",
-      "display_name": "plain-servlet-windows",
-      "notes": "",
-      "versus": ""
     }
   }]
 }

BIN
plain/lib/plain-library_2.10-1.0.1-SNAPSHOT.jar


+ 2 - 2
plain/src/main/resources/application.conf

@@ -29,7 +29,7 @@ benchmark-dispatcher.routes = [
 	{ uri = db, resource-class-name = com.ibm.techempower.Db }
 	{ uri = update, resource-class-name = com.ibm.techempower.Update }
 	{ uri = fortunes, resource-class-name = com.ibm.techempower.Fortunes }
-	{ uri = "web-apps*", resource-class-name = com.ibm.plain.rest.resource.ServletResource }
+	{ uri = "web-apps*", resource-class-name = com.ibm.plain.servlet.ServletResource }
 ]
 
 benchmark-mysql {
@@ -37,7 +37,7 @@ benchmark-mysql {
 	jndi-lookup-name = "jdbc/hello_world"
 	driver = mysql-5-6-12
 	datasource-settings {	
-		setUrl = "jdbc:mysql://127.0.0.1:3306/hello_world?jdbcCompliantTruncation=false&elideSetAutoCommits=false&dontTrackOpenResources=true&enableQueryTimeouts=false&useLocalSessionState=false&cachePrepStmts=true&cacheCallableStmts=true&alwaysSendSetIsolation=false&prepStmtCacheSize=1024&cacheServerConfiguration=true&prepStmtCacheSqlLimit=2048&zeroDateTimeBehavior=convertToNull&traceProtocol=false&useUnbufferedInput=false&useReadAheadInput=true&maintainTimeStats=false&useServerPrepStmts&cacheRSMetadata=true&poolPreparedStatements=true"
+		setUrl = "jdbc:mysql://127.0.0.1:3306/hello_world?jdbcCompliantTruncation=false&elideSetAutoCommits=true&useLocalSessionState=true&cachePrepStmts=true&cacheCallableStmts=true&alwaysSendSetIsolation=false&prepStmtCacheSize=4096&cacheServerConfiguration=true&prepStmtCacheSqlLimit=2048&zeroDateTimeBehavior=convertToNull&traceProtocol=false&useUnbufferedInput=false&useReadAheadInput=false&maintainTimeStats=false&useServerPrepStmts&cacheRSMetadata=true"
 		setUser = benchmarkdbuser
 		setPassword = benchmarkdbpass
 	}	

+ 8 - 2
plain/src/main/scala/com/ibm/techempower/PlainText.scala

@@ -11,12 +11,18 @@ final class PlainText
 
   import PlainText._
 
-  Get { hello }
+  Get { hello.duplicate }
 
 }
 
 object PlainText {
 
-  private final val hello = "Hello, World!".getBytes(`UTF-8`)
+  private final val hello = {
+    val a = "Hello, World!".getBytes(`UTF-8`)
+    val buf = ByteBuffer.allocateDirect(a.length)
+    buf.put(a)
+    buf.flip
+    buf
+  }
 
 }

BIN
plain/web-apps/servlet.war