Browse Source

Actix: unify and optimize platform benchmarks (#3806)

* merge raw benchmarks

* optimize platform benchmarks
Nikolay Kim 7 years ago
parent
commit
724a773096

+ 50 - 50
frameworks/Rust/actix/Cargo.lock

@@ -34,9 +34,9 @@ dependencies = [
  "num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "postgres 0.15.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde_derive 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde_json 1.0.17 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde_derive 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde_json 1.0.19 (registry+https://github.com/rust-lang/crates.io-index)",
  "tokio-core 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "tokio-io 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -61,7 +61,7 @@ dependencies = [
  "http-range 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "httparse 1.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "language-tags 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "lazy_static 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.41 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "mime 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -72,8 +72,8 @@ dependencies = [
  "percent-encoding 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "regex 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde_json 1.0.17 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde_json 1.0.19 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_urlencoded 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "sha1 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "slab 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -150,7 +150,7 @@ name = "backtrace"
 version = "0.2.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "backtrace-sys 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
+ "backtrace-sys 0.1.23 (registry+https://github.com/rust-lang/crates.io-index)",
  "cfg-if 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "dbghelp-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -164,7 +164,7 @@ name = "backtrace"
 version = "0.3.8"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "backtrace-sys 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
+ "backtrace-sys 0.1.23 (registry+https://github.com/rust-lang/crates.io-index)",
  "cfg-if 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.41 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-demangle 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -173,10 +173,10 @@ dependencies = [
 
 [[package]]
 name = "backtrace-sys"
-version = "0.1.21"
+version = "0.1.23"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "cc 1.0.15 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cc 1.0.17 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.41 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -248,14 +248,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "error-chain 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde_derive 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde_json 1.0.17 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde_derive 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde_json 1.0.19 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "cc"
-version = "1.0.15"
+version = "1.0.17"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
@@ -303,7 +303,7 @@ dependencies = [
  "arrayvec 0.4.7 (registry+https://github.com/rust-lang/crates.io-index)",
  "cfg-if 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "crossbeam-utils 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "lazy_static 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "memoffset 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -640,7 +640,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "lazy_static"
-version = "1.0.0"
+version = "1.0.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
@@ -922,7 +922,7 @@ dependencies = [
 
 [[package]]
 name = "proc-macro2"
-version = "0.4.3"
+version = "0.4.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -938,7 +938,7 @@ dependencies = [
 
 [[package]]
 name = "quick-error"
-version = "1.2.1"
+version = "1.2.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
@@ -956,10 +956,10 @@ dependencies = [
 
 [[package]]
 name = "quote"
-version = "0.6.2"
+version = "0.6.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "proc-macro2 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
+ "proc-macro2 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1001,7 +1001,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "redox_syscall"
-version = "0.1.38"
+version = "0.1.40"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
@@ -1038,7 +1038,7 @@ version = "0.6.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "hostname 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
- "quick-error 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "quick-error 1.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1075,7 +1075,7 @@ version = "0.9.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1085,27 +1085,27 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "serde"
-version = "1.0.61"
+version = "1.0.64"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "serde_derive"
-version = "1.0.61"
+version = "1.0.64"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "proc-macro2 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "quote 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "syn 0.14.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "proc-macro2 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "quote 0.6.3 (registry+https://github.com/rust-lang/crates.io-index)",
+ "syn 0.14.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "serde_json"
-version = "1.0.17"
+version = "1.0.19"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "itoa 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1115,7 +1115,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "itoa 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1150,7 +1150,7 @@ dependencies = [
  "error-chain 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "pulldown-cmark 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "serde_json 1.0.17 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde_json 1.0.19 (registry+https://github.com/rust-lang/crates.io-index)",
  "tempdir 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
  "walkdir 2.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -1216,11 +1216,11 @@ dependencies = [
 
 [[package]]
 name = "syn"
-version = "0.14.0"
+version = "0.14.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "proc-macro2 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "quote 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "proc-macro2 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "quote 0.6.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1255,7 +1255,7 @@ name = "thread_local"
 version = "0.3.5"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "lazy_static 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "unreachable 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1265,7 +1265,7 @@ version = "0.1.40"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "libc 0.2.41 (registry+https://github.com/rust-lang/crates.io-index)",
- "redox_syscall 0.1.38 (registry+https://github.com/rust-lang/crates.io-index)",
+ "redox_syscall 0.1.40 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1317,7 +1317,7 @@ dependencies = [
  "error-chain 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "idna 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "lazy_static 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "tokio-core 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1333,7 +1333,7 @@ dependencies = [
  "error-chain 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "ipconfig 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "lazy_static 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "lru-cache 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "resolv-conf 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1518,7 +1518,7 @@ dependencies = [
 "checksum askama_shared 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)" = "72764966f241ed1143792ec29805df7eec322800b2b402781d86339e66f512b6"
 "checksum backtrace 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "346d7644f0b5f9bc73082d3b2236b69a05fd35cce0cfa3724e184e6a5c9e2a2f"
 "checksum backtrace 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)" = "dbdd17cd962b570302f5297aea8648d5923e22e555c2ed2d8b2e34eca646bf6d"
-"checksum backtrace-sys 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)" = "b46a4e68c24954dfc8a0e515b069f695481d2997b840356db013ff9e52cdb8fe"
+"checksum backtrace-sys 0.1.23 (registry+https://github.com/rust-lang/crates.io-index)" = "bff67d0c06556c0b8e6b5f090f0eac52d950d9dfd1d35ba04e4ca3543eaf6a7e"
 "checksum base64 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "96434f987501f0ed4eb336a411e0631ecd1afa11574fe148587adc4ff96143c9"
 "checksum base64 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9263aa6a38da271eec5c91a83ce1e800f093c8535788d403d626d8d5c3f8f007"
 "checksum bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "4efd02e230a02e18f92fc2735f44597385ed02ad8f831e7c1c1156ee5e1ab3a5"
@@ -1529,7 +1529,7 @@ dependencies = [
 "checksum byteorder 1.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "74c0b906e9446b0a2e4f760cdb3fa4b2c48cdc6db8766a845c54b6ff063fd2e9"
 "checksum bytes 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)" = "7dd32989a66957d3f0cba6588f15d4281a733f4e9ffc43fcd2385f57d3bf99ff"
 "checksum cargo_metadata 0.5.4 (registry+https://github.com/rust-lang/crates.io-index)" = "6ebd6272a2ca4fd39dbabbd6611eb03df45c2259b3b80b39a9ff8fbdcf42a4b3"
-"checksum cc 1.0.15 (registry+https://github.com/rust-lang/crates.io-index)" = "0ebb87d1116151416c0cf66a0e3fb6430cccd120fd6300794b4dfaa050ac40ba"
+"checksum cc 1.0.17 (registry+https://github.com/rust-lang/crates.io-index)" = "49ec142f5768efb5b7622aebc3fdbdbb8950a4b9ba996393cb76ef7466e8747d"
 "checksum cfg-if 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "405216fd8fe65f718daa7102ea808a946b6ce40c742998fbfd3463645552de18"
 "checksum cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "ddfc5b9aa5d4507acaf872de71051dfd0e309860e88966e1051e462a077aac4f"
 "checksum constant_time_eq 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "8ff012e225ce166d4422e0e78419d901719760f62ae2b7969ca6b564d1b54a9e"
@@ -1578,7 +1578,7 @@ dependencies = [
 "checksum itoa 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c069bbec61e1ca5a596166e55dfe4773ff745c3d16b700013bcaff9a6df2c682"
 "checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d"
 "checksum language-tags 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "a91d884b6667cd606bb5a69aa0c99ba811a115fc68915e7056ec08a46e93199a"
-"checksum lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c8f31047daa365f19be14b47c29df4f7c3b581832407daabe6ae77397619237d"
+"checksum lazy_static 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "e6412c5e2ad9584b0b8e979393122026cdd6d2a80b933f890dcd694ddbe73739"
 "checksum lazycell 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a6f08839bc70ef4a3fe1d566d5350f519c5912ea86be0df1740a7d247c7fc0ef"
 "checksum libc 0.2.41 (registry+https://github.com/rust-lang/crates.io-index)" = "ac8ebf8343a981e2fa97042b14768f02ed3e1d602eac06cae6166df3c8ced206"
 "checksum linked-hash-map 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7860ec297f7008ff7a1e3382d7f7e1dcd69efc94751a2284bafc3d013c2aa939"
@@ -1611,17 +1611,17 @@ dependencies = [
 "checksum postgres-shared 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "bafecadf25b7de9a5f747e93073db444c9ddcc7b3ae37bcdf63c2508f9a17f2d"
 "checksum pq-sys 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)" = "9323a6ce484fc41174d40f80ba87af6247f86a7ba57856af68d3aa0c8642d2f0"
 "checksum proc-macro2 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)" = "1b06e2f335f48d24442b35a19df506a835fb3547bc3c06ef27340da9acf5cae7"
-"checksum proc-macro2 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)" = "a45f2f0ae0b5757f6fe9e68745ba25f5246aea3598984ed81d013865873c1f84"
+"checksum proc-macro2 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "1fa93823f53cfd0f5ac117b189aed6cfdfb2cfc0a9d82e956dd7927595ed7d46"
 "checksum pulldown-cmark 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "d6fdf85cda6cadfae5428a54661d431330b312bc767ddbc57adbedc24da66e32"
-"checksum quick-error 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "eda5fe9b71976e62bc81b781206aaa076401769b2143379d3eb2118388babac4"
+"checksum quick-error 1.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "9274b940887ce9addde99c4eee6b5c44cc494b182b97e73dc8ffdcb3397fd3f0"
 "checksum quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6e920b65c65f10b2ae65c831a81a073a89edd28c7cce89475bff467ab4167a"
 "checksum quote 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "9949cfe66888ffe1d53e6ec9d9f3b70714083854be20fd5e271b232a017401e8"
-"checksum quote 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)" = "9e53eeda07ddbd8b057dde66d9beded11d0dfda13f0db0769e6b71d6bcf2074e"
+"checksum quote 0.6.3 (registry+https://github.com/rust-lang/crates.io-index)" = "e44651a0dc4cdd99f71c83b561e221f714912d11af1a4dff0631f923d53af035"
 "checksum rand 0.3.22 (registry+https://github.com/rust-lang/crates.io-index)" = "15a732abf9d20f0ad8eeb6f909bf6868722d9a06e1e50802b6a70351f40b4eb1"
 "checksum rand 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "eba5f8cb59cc50ed56be8880a5c7b496bfd9bd26394e176bc67884094145c2c5"
 "checksum rand 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7a89abf8d34faf9783692392dca7bcdc6e82fa84eca86ccb6301ec87f3497185"
 "checksum rand_core 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1b7a5f27547c49e5ccf8a586db3f3782fd93cf849780b21853b9d981db203302"
-"checksum redox_syscall 0.1.38 (registry+https://github.com/rust-lang/crates.io-index)" = "0a12d51a5b5fd700e6c757f15877685bfa04fd7eb60c108f01d045cafa0073c2"
+"checksum redox_syscall 0.1.40 (registry+https://github.com/rust-lang/crates.io-index)" = "c214e91d3ecf43e9a4e41e578973adeb14b474f2bee858742d127af75a0112b1"
 "checksum regex 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "75ecf88252dce580404a22444fc7d626c01815debba56a7f4f536772a5ff19d3"
 "checksum regex-syntax 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8f1ac0f60d675cc6cf13a20ec076568254472551051ad5dd050364d70671bf6b"
 "checksum remove_dir_all 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "3488ba1b9a2084d38645c4c08276a1752dcbf2c7130d74f1569681ad5d2799c5"
@@ -1633,9 +1633,9 @@ dependencies = [
 "checksum scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "94258f53601af11e6a49f722422f6e3425c52b06245a5cf9bc09908b174f5e27"
 "checksum semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1d7eb9ef2c18661902cc47e535f9bc51b78acd254da71d375c2f6720d9a40403"
 "checksum semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3"
-"checksum serde 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)" = "d7134c98234af4b842287fa3e40860ccf4e838f8f3c6909bd9da5fe4cbe41ea6"
-"checksum serde_derive 1.0.61 (registry+https://github.com/rust-lang/crates.io-index)" = "d04ba8ea0d548a043f5117c5e91c00251b02d10dc89ec846c62ac954816a49a9"
-"checksum serde_json 1.0.17 (registry+https://github.com/rust-lang/crates.io-index)" = "f3ad6d546e765177cf3dded3c2e424a8040f870083a0e64064746b958ece9cb1"
+"checksum serde 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)" = "fba5be06346c5200249c8c8ca4ccba4a09e8747c71c16e420bd359a0db4d8f91"
+"checksum serde_derive 1.0.64 (registry+https://github.com/rust-lang/crates.io-index)" = "79e4620ba6fbe051fc7506fab6f84205823564d55da18d55b695160fb3479cd8"
+"checksum serde_json 1.0.19 (registry+https://github.com/rust-lang/crates.io-index)" = "93aee34bb692dde91e602871bc792dd319e489c7308cdbbe5f27cf27c64280f5"
 "checksum serde_urlencoded 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "e703cef904312097cfceab9ce131ff6bbe09e8c964a0703345a5f49238757bc1"
 "checksum sha1 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "2579985fda508104f7587689507983eadd6a6e84dd35d6d115361f530916fa0d"
 "checksum sha2 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9eb6be24e4c23a84d7184280d2722f7f2731fcdd4a9d886efbfe4413e4847ea0"
@@ -1649,7 +1649,7 @@ dependencies = [
 "checksum stringprep 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "8ee348cb74b87454fff4b551cbf727025810a004f88aeacae7f85b87f4e9a1c1"
 "checksum syn 0.11.11 (registry+https://github.com/rust-lang/crates.io-index)" = "d3b891b9015c88c576343b9b3e41c2c11a51c219ef067b264bd9c8aa9b441dad"
 "checksum syn 0.13.11 (registry+https://github.com/rust-lang/crates.io-index)" = "14f9bf6292f3a61d2c716723fdb789a41bbe104168e6f496dc6497e531ea1b9b"
-"checksum syn 0.14.0 (registry+https://github.com/rust-lang/crates.io-index)" = "99d991a9e7c33123925e511baab68f7ec25c3795962fe326a2395e5a42a614f0"
+"checksum syn 0.14.1 (registry+https://github.com/rust-lang/crates.io-index)" = "6dfd71b2be5a58ee30a6f8ea355ba8290d397131c00dfa55c3d34e6e13db5101"
 "checksum synom 0.11.3 (registry+https://github.com/rust-lang/crates.io-index)" = "a393066ed9010ebaed60b9eafa373d4b1baac186dd7e008555b0f702b51945b6"
 "checksum synstructure 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "3a761d12e6d8dcb4dcf952a7a89b475e3a9d69e4a69307e01a470977642914bd"
 "checksum tempdir 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)" = "15f2b5fb00ccdf689e0149d1b1b3c03fead81c2b37735d812fa8bddbbf41b6d8"

+ 0 - 4
frameworks/Rust/actix/Cargo.toml

@@ -11,10 +11,6 @@ path = "src/main.rs"
 name = "actix-raw"
 path = "src/main_raw.rs"
 
-[[bin]]
-name = "actix-raw-db"
-path = "src/main_raw_db.rs"
-
 [[bin]]
 name = "actix-diesel"
 path = "src/main_diesel.rs"

+ 0 - 9
frameworks/Rust/actix/actix-raw-db.dockerfile

@@ -1,9 +0,0 @@
-FROM rust:1.26
-
-ADD ./ /actix
-WORKDIR /actix
-
-RUN cargo clean
-RUN RUSTFLAGS="-C target-cpu=native" cargo build --release
-
-CMD ./target/release/actix-raw-db

+ 1 - 17
frameworks/Rust/actix/benchmark_config.json

@@ -23,22 +23,6 @@
       "fortune_url": "/fortune",
       "json_url": "/json",
       "plaintext_url": "/plaintext",
-      "port": 8080,
-      "approach": "Realistic",
-      "classification": "Platform",
-      "database": "Postgres",
-      "framework": "actix",
-      "language": "Rust",
-      "orm": "Raw",
-      "platform": "None",
-      "webserver": "actix-web",
-      "os": "Linux",
-      "database_os": "Linux",
-      "display_name": "Actix [raw]",
-      "notes": "",
-      "versus": ""
-    },
-    "raw-db": {
       "db_url": "/db",
       "query_url": "/queries?q=",
       "update_url": "/updates?q=",
@@ -53,7 +37,7 @@
       "webserver": "actix-web",
       "os": "Linux",
       "database_os": "Linux",
-      "display_name": "Actix [pg-raw]",
+      "display_name": "Actix [raw]",
       "notes": "",
       "versus": ""
     },

+ 2 - 1
frameworks/Rust/actix/src/db_pg.rs

@@ -114,7 +114,8 @@ impl Handler<UpdateWorld> for PgConnection {
         worlds.sort_by_key(|w| w.id);
 
         update.pop();
-        update.push_str(" ORDER BY 1) AS temp(id, randomnumber) WHERE temp.id = world.id");
+        update
+            .push_str(" ORDER BY 1) AS temp(id, randomnumber) WHERE temp.id = world.id");
         self.conn.execute(&update, &[]).unwrap();
 
         Ok(worlds)

+ 148 - 13
frameworks/Rust/actix/src/main_raw.rs

@@ -14,7 +14,7 @@ extern crate rand;
 #[macro_use]
 extern crate diesel;
 
-use std::io;
+use std::{cmp, mem};
 
 use actix::prelude::*;
 use actix_web::server::{self, HttpHandler, HttpHandlerTask, HttpServer, Writer};
@@ -27,8 +27,8 @@ mod db_pg;
 mod models;
 mod utils;
 
-use db_pg::{PgConnection, TellFortune};
-use utils::{Message, Writer as JsonWriter};
+use db_pg::{PgConnection, RandomWorld, RandomWorlds, TellFortune, UpdateWorld};
+use utils::{Message, StackWriter, Writer as JsonWriter};
 
 const HTTPOK: &[u8] = b"HTTP/1.1 200 OK\r\n";
 const HDR_SERVER: &[u8] = b"Server: Actix\r\n";
@@ -48,9 +48,45 @@ impl HttpHandler for App {
             match path.len() {
                 10 if path == "/plaintext" => return Ok(Box::new(Plaintext)),
                 5 if path == "/json" => return Ok(Box::new(Json)),
+                3 if path == "/db" => {
+                    return Ok(Box::new(World {
+                        fut: self.db.send(RandomWorld),
+                    }))
+                }
                 8 if path == "/fortune" => {
-                    let fut = Box::new(self.db.send(TellFortune));
-                    return Ok(Box::new(Fortune { fut }));
+                    return Ok(Box::new(Fortune {
+                        fut: self.db.send(TellFortune),
+                    }));
+                }
+                8 if path == "/queries" => {
+                    let q = req
+                        .query()
+                        .get("q")
+                        .map(|q| {
+                            cmp::min(
+                                500,
+                                cmp::max(1, q.parse::<u16>().ok().unwrap_or(1)),
+                            )
+                        })
+                        .unwrap_or(1);
+                    return Ok(Box::new(Queries {
+                        fut: self.db.send(RandomWorlds(q)),
+                    }));
+                }
+                8 if path == "/updates" => {
+                    let q = req
+                        .query()
+                        .get("q")
+                        .map(|q| {
+                            cmp::min(
+                                500,
+                                cmp::max(1, q.parse::<u16>().ok().unwrap_or(1)),
+                            )
+                        })
+                        .unwrap_or(1);
+                    return Ok(Box::new(Updates {
+                        fut: self.db.send(UpdateWorld(q)),
+                    }));
                 }
                 _ => (),
             }
@@ -96,9 +132,7 @@ impl HttpHandlerTask for Json {
 }
 
 struct Fortune {
-    fut: Box<
-        Future<Item = io::Result<Vec<models::Fortune>>, Error = actix::MailboxError>,
-    >,
+    fut: actix::dev::Request<Syn, PgConnection, TellFortune>,
 }
 
 #[derive(Template)]
@@ -111,17 +145,118 @@ impl HttpHandlerTask for Fortune {
     fn poll_io(&mut self, io: &mut Writer) -> Poll<bool, Error> {
         match self.fut.poll() {
             Ok(Async::Ready(Ok(rows))) => {
-                let tmpl = FortuneTemplate { items: &rows };
-                let body = tmpl.render().unwrap();
+                let mut body: [u8; 2048] = unsafe { mem::uninitialized() };
+                let len = {
+                    let mut writer = StackWriter(&mut body, 0);
+                    let tmpl = FortuneTemplate { items: &rows };
+                    tmpl.render_into(&mut writer).unwrap();
+                    writer.1
+                };
 
                 let mut bytes = io.buffer();
-                bytes.reserve(196 + body.len());
+                bytes.reserve(196 + len);
                 bytes.extend_from_slice(HTTPOK);
                 bytes.extend_from_slice(HDR_SERVER);
                 bytes.extend_from_slice(HDR_CTHTML);
-                server::write_content_length(body.len(), &mut bytes);
+                server::write_content_length(len, &mut bytes);
+                io.set_date(bytes);
+                bytes.extend_from_slice(&body[..len]);
+                Ok(Async::Ready(true))
+            }
+            Ok(Async::NotReady) => Ok(Async::NotReady),
+            Ok(Async::Ready(Err(e))) => Err(e.into()),
+            Err(e) => Err(e.into()),
+        }
+    }
+}
+
+struct World {
+    fut: actix::dev::Request<Syn, PgConnection, RandomWorld>,
+}
+
+impl HttpHandlerTask for World {
+    fn poll_io(&mut self, io: &mut Writer) -> Poll<bool, Error> {
+        match self.fut.poll() {
+            Ok(Async::Ready(Ok(row))) => {
+                let mut body: [u8; 48] = unsafe { mem::uninitialized() };
+                let len = {
+                    let mut writer = StackWriter(&mut body, 0);
+                    serde_json::to_writer(&mut writer, &row).unwrap();
+                    writer.1
+                };
+
+                let mut bytes = io.buffer();
+                bytes.reserve(196);
+                bytes.extend_from_slice(HTTPOK);
+                bytes.extend_from_slice(HDR_SERVER);
+                bytes.extend_from_slice(HDR_CTJSON);
+                server::write_content_length(len, &mut bytes);
+                io.set_date(bytes);
+                bytes.extend_from_slice(&body[..len]);
+                Ok(Async::Ready(true))
+            }
+            Ok(Async::NotReady) => Ok(Async::NotReady),
+            Ok(Async::Ready(Err(e))) => Err(e.into()),
+            Err(e) => Err(e.into()),
+        }
+    }
+}
+
+struct Queries {
+    fut: actix::dev::Request<Syn, PgConnection, RandomWorlds>,
+}
+
+impl HttpHandlerTask for Queries {
+    fn poll_io(&mut self, io: &mut Writer) -> Poll<bool, Error> {
+        match self.fut.poll() {
+            Ok(Async::Ready(Ok(worlds))) => {
+                let mut body: [u8; 24576] = unsafe { mem::uninitialized() };
+                let len = {
+                    let mut writer = StackWriter(&mut body, 0);
+                    serde_json::to_writer(&mut writer, &worlds).unwrap();
+                    writer.1
+                };
+
+                let mut bytes = io.buffer();
+                bytes.reserve(196 + len);
+                bytes.extend_from_slice(HTTPOK);
+                bytes.extend_from_slice(HDR_SERVER);
+                bytes.extend_from_slice(HDR_CTJSON);
+                server::write_content_length(len, &mut bytes);
+                io.set_date(bytes);
+                bytes.extend_from_slice(&body[..len]);
+                Ok(Async::Ready(true))
+            }
+            Ok(Async::NotReady) => Ok(Async::NotReady),
+            Ok(Async::Ready(Err(e))) => Err(e.into()),
+            Err(e) => Err(e.into()),
+        }
+    }
+}
+
+struct Updates {
+    fut: actix::dev::Request<Syn, PgConnection, UpdateWorld>,
+}
+
+impl HttpHandlerTask for Updates {
+    fn poll_io(&mut self, io: &mut Writer) -> Poll<bool, Error> {
+        match self.fut.poll() {
+            Ok(Async::Ready(Ok(worlds))) => {
+                let mut body: [u8; 24576] = unsafe { mem::uninitialized() };
+                let len = {
+                    let mut writer = StackWriter(&mut body, 0);
+                    serde_json::to_writer(&mut writer, &worlds).unwrap();
+                    writer.1
+                };
+
+                let mut bytes = io.buffer();
+                bytes.reserve(196 + len);
+                bytes.extend_from_slice(HTTPOK);
+                bytes.extend_from_slice(HDR_SERVER);
+                bytes.extend_from_slice(HDR_CTJSON);
+                server::write_content_length(len, &mut bytes);
                 io.set_date(bytes);
-                bytes.extend_from_slice(body.as_ref());
+                bytes.extend_from_slice(&body[..len]);
                 Ok(Async::Ready(true))
             }
             Ok(Async::NotReady) => Ok(Async::NotReady),

+ 0 - 184
frameworks/Rust/actix/src/main_raw_db.rs

@@ -1,184 +0,0 @@
-extern crate actix;
-extern crate actix_web;
-extern crate bytes;
-extern crate futures;
-extern crate serde;
-extern crate serde_json;
-#[macro_use]
-extern crate serde_derive;
-extern crate num_cpus;
-extern crate postgres;
-extern crate rand;
-#[macro_use]
-extern crate diesel;
-
-use std::{cmp, io};
-
-use actix::prelude::*;
-use actix_web::server::{self, HttpHandler, HttpHandlerTask, HttpServer, Writer};
-use actix_web::{Error, HttpRequest};
-use bytes::BytesMut;
-use futures::{Async, Future, Poll};
-use postgres::{Connection, TlsMode};
-
-mod db_pg;
-mod models;
-mod utils;
-
-use db_pg::{PgConnection, RandomWorld, RandomWorlds, UpdateWorld};
-use utils::Writer as JsonWriter;
-
-const HTTPOK: &[u8] = b"HTTP/1.1 200 OK\r\n";
-const HDR_SERVER: &[u8] = b"Server: Actix\r\n";
-const HDR_JSON: &[u8] = b"Content-Type: application/json";
-
-struct App {
-    db: Addr<Syn, PgConnection>,
-}
-
-impl HttpHandler for App {
-    fn handle(&mut self, req: HttpRequest) -> Result<Box<HttpHandlerTask>, HttpRequest> {
-        match req.path() {
-            "/db" => Ok(Box::new(World {
-                fut: Box::new(self.db.send(RandomWorld)),
-            })),
-            "/queries" => {
-                let q = req
-                    .query()
-                    .get("q")
-                    .map(|q| {
-                        cmp::min(500, cmp::max(1, q.parse::<u16>().ok().unwrap_or(1)))
-                    })
-                    .unwrap_or(1);
-                Ok(Box::new(Queries {
-                    fut: Box::new(self.db.send(RandomWorlds(q))),
-                }))
-            }
-            "/updates" => {
-                let q = req
-                    .query()
-                    .get("q")
-                    .map(|q| {
-                        cmp::min(500, cmp::max(1, q.parse::<u16>().ok().unwrap_or(1)))
-                    })
-                    .unwrap_or(1);
-                Ok(Box::new(Updates {
-                    fut: Box::new(self.db.send(UpdateWorld(q))),
-                }))
-            }
-            _ => Err(req),
-        }
-    }
-}
-
-struct World {
-    fut: Box<Future<Item = io::Result<models::World>, Error = actix::MailboxError>>,
-}
-
-impl HttpHandlerTask for World {
-    fn poll_io(&mut self, io: &mut Writer) -> Poll<bool, Error> {
-        match self.fut.poll() {
-            Ok(Async::Ready(Ok(row))) => {
-                let mut body = BytesMut::with_capacity(31);
-                serde_json::to_writer(JsonWriter(&mut body), &row).unwrap();
-
-                let mut bytes = io.buffer();
-                bytes.reserve(196);
-                bytes.extend_from_slice(HTTPOK);
-                bytes.extend_from_slice(HDR_SERVER);
-                bytes.extend_from_slice(HDR_JSON);
-                server::write_content_length(body.len(), &mut bytes);
-                io.set_date(bytes);
-                bytes.extend_from_slice(body.as_ref());
-                Ok(Async::Ready(true))
-            }
-            Ok(Async::NotReady) => Ok(Async::NotReady),
-            Ok(Async::Ready(Err(e))) => Err(e.into()),
-            Err(e) => Err(e.into()),
-        }
-    }
-}
-
-struct Queries {
-    fut: Box<Future<Item = io::Result<Vec<models::World>>, Error = actix::MailboxError>>,
-}
-
-impl HttpHandlerTask for Queries {
-    fn poll_io(&mut self, io: &mut Writer) -> Poll<bool, Error> {
-        match self.fut.poll() {
-            Ok(Async::Ready(Ok(worlds))) => {
-                let mut body = BytesMut::with_capacity(35 * worlds.len());
-                serde_json::to_writer(JsonWriter(&mut body), &worlds).unwrap();
-
-                let mut bytes = io.buffer();
-                bytes.reserve(196);
-                bytes.extend_from_slice(HTTPOK);
-                bytes.extend_from_slice(HDR_SERVER);
-                bytes.extend_from_slice(HDR_JSON);
-                server::write_content_length(body.len(), &mut bytes);
-                io.set_date(bytes);
-                bytes.extend_from_slice(body.as_ref());
-                Ok(Async::Ready(true))
-            }
-            Ok(Async::NotReady) => Ok(Async::NotReady),
-            Ok(Async::Ready(Err(e))) => Err(e.into()),
-            Err(e) => Err(e.into()),
-        }
-    }
-}
-
-struct Updates {
-    fut: Box<Future<Item = io::Result<Vec<models::World>>, Error = actix::MailboxError>>,
-}
-
-impl HttpHandlerTask for Updates {
-    fn poll_io(&mut self, io: &mut Writer) -> Poll<bool, Error> {
-        match self.fut.poll() {
-            Ok(Async::Ready(Ok(worlds))) => {
-                let mut body = BytesMut::with_capacity(35 * worlds.len());
-                serde_json::to_writer(JsonWriter(&mut body), &worlds).unwrap();
-
-                let mut bytes = io.buffer();
-                bytes.reserve(196 + body.len());
-                bytes.extend_from_slice(HTTPOK);
-                bytes.extend_from_slice(HDR_SERVER);
-                bytes.extend_from_slice(HDR_JSON);
-                server::write_content_length(body.len(), &mut bytes);
-                io.set_date(bytes);
-                bytes.extend_from_slice(body.as_ref());
-                Ok(Async::Ready(true))
-            }
-            Ok(Async::NotReady) => Ok(Async::NotReady),
-            Ok(Async::Ready(Err(e))) => Err(e.into()),
-            Err(e) => Err(e.into()),
-        }
-    }
-}
-
-fn main() {
-    let sys = System::new("techempower");
-    let db_url = "postgres://benchmarkdbuser:benchmarkdbpass@tfb-database/hello_world";
-
-    // Avoid triggering "FATAL: the database system is starting up" error from
-    // postgres.
-    {
-        if Connection::connect(db_url, TlsMode::None).is_err() {
-            std::thread::sleep(std::time::Duration::from_secs(5));
-        }
-    }
-
-    // Start db executor actors
-    let addr = SyncArbiter::start(num_cpus::get() * 3, move || {
-        db_pg::PgConnection::new(db_url)
-    });
-
-    // start http server
-    HttpServer::new(move || vec![App { db: addr.clone() }])
-        .backlog(8192)
-        .bind("0.0.0.0:8080")
-        .unwrap()
-        .start();
-
-    println!("Started http server: 127.0.0.1:8080");
-    let _ = sys.run();
-}

+ 33 - 2
frameworks/Rust/actix/src/utils.rs

@@ -1,8 +1,8 @@
 #![allow(dead_code)]
 use bytes::BytesMut;
-use std::io;
+use std::{fmt, io};
 
-pub const SIZE: usize = 27;
+pub const SIZE: usize = 31;
 
 #[derive(Serialize, Deserialize)]
 pub struct Message {
@@ -20,3 +20,34 @@ impl<'a> io::Write for Writer<'a> {
         Ok(())
     }
 }
+
+pub struct StackWriter<'a>(pub &'a mut [u8], pub usize);
+
+impl<'a> io::Write for StackWriter<'a> {
+    #[inline]
+    fn write(&mut self, buf: &[u8]) -> io::Result<usize> {
+        let l = buf.len();
+        let new = self.1 + l;
+        self.0[self.1..new].copy_from_slice(buf);
+        self.1 = new;
+        Ok(l)
+    }
+    #[inline]
+    fn flush(&mut self) -> io::Result<()> {
+        Ok(())
+    }
+}
+
+impl<'a> fmt::Write for StackWriter<'a> {
+    #[inline]
+    fn write_str(&mut self, s: &str) -> Result<(), fmt::Error> {
+        if !s.is_empty() {
+            let b = s.as_bytes();
+            let l = b.len();
+            let new = self.1 + l;
+            self.0[self.1..new].copy_from_slice(b);
+            self.1 = new;
+        }
+        Ok(())
+    }
+}