浏览代码

Use actix-web 0.5 release (#3573)

Nikolay Kim 7 年之前
父节点
当前提交
f2f177b406

+ 87 - 38
frameworks/Rust/actix/Cargo.lock

@@ -1,13 +1,13 @@
 [[package]]
 name = "actix"
-version = "0.3.0"
+version = "0.4.0"
 dependencies = [
  "actix 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)",
- "actix-web 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)",
- "askama 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "actix-web 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "askama 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "bytes 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "diesel 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "diesel 1.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "http 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "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)",
@@ -29,7 +29,7 @@ dependencies = [
  "bytes 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "crossbeam-channel 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "failure 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.39 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "skeptic 0.13.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -43,7 +43,7 @@ dependencies = [
 
 [[package]]
 name = "actix-web"
-version = "0.4.10"
+version = "0.5.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "actix 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -56,13 +56,14 @@ dependencies = [
  "encoding 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)",
  "failure 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "flate2 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "futures-cpupool 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "h2 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "http 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "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)",
  "libc 0.2.39 (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.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -75,6 +76,7 @@ dependencies = [
  "regex 0.2.10 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_json 1.0.13 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde_urlencoded 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "sha1 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "skeptic 0.13.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -120,31 +122,30 @@ dependencies = [
 
 [[package]]
 name = "askama"
-version = "0.5.0"
+version = "0.6.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "askama_derive 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "askama_shared 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "askama_derive 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "askama_shared 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "askama_derive"
-version = "0.5.0"
+version = "0.6.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "askama_shared 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "syn 0.11.11 (registry+https://github.com/rust-lang/crates.io-index)",
+ "askama_shared 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "nom 3.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "quote 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "syn 0.13.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "askama_shared"
-version = "0.5.0"
+version = "0.6.1"
 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)",
- "nom 3.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)",
- "syn 0.11.11 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -373,22 +374,23 @@ dependencies = [
 
 [[package]]
 name = "diesel"
-version = "1.1.1"
+version = "1.2.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "diesel_derives 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "diesel_derives 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "pq-sys 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "diesel_derives"
-version = "1.1.0"
+version = "1.2.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)",
- "syn 0.11.11 (registry+https://github.com/rust-lang/crates.io-index)",
+ "proc-macro2 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
+ "quote 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "syn 0.12.14 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -544,7 +546,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "futures"
-version = "0.1.19"
+version = "0.1.21"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
@@ -552,7 +554,7 @@ name = "futures-cpupool"
 version = "0.1.8"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -582,7 +584,7 @@ dependencies = [
  "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "bytes 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "http 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "indexmap 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -669,6 +671,11 @@ dependencies = [
  "winreg 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
+[[package]]
+name = "itoa"
+version = "0.3.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+
 [[package]]
 name = "itoa"
 version = "0.4.1"
@@ -993,6 +1000,14 @@ dependencies = [
  "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
+[[package]]
+name = "proc-macro2"
+version = "0.3.6"
+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)",
+]
+
 [[package]]
 name = "pulldown-cmark"
 version = "0.1.2"
@@ -1019,6 +1034,14 @@ dependencies = [
  "proc-macro2 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
+[[package]]
+name = "quote"
+version = "0.5.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+dependencies = [
+ "proc-macro2 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
+]
+
 [[package]]
 name = "rand"
 version = "0.3.22"
@@ -1192,6 +1215,17 @@ dependencies = [
  "serde 1.0.34 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
+[[package]]
+name = "serde_urlencoded"
+version = "0.5.1"
+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.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "serde 1.0.34 (registry+https://github.com/rust-lang/crates.io-index)",
+ "url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
+]
+
 [[package]]
 name = "sha1"
 version = "0.6.0"
@@ -1287,6 +1321,16 @@ dependencies = [
  "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
+[[package]]
+name = "syn"
+version = "0.13.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+dependencies = [
+ "proc-macro2 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
+ "quote 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
+]
+
 [[package]]
 name = "synom"
 version = "0.11.3"
@@ -1338,7 +1382,7 @@ version = "0.1.12"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bytes 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "mio 0.6.14 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1353,7 +1397,7 @@ version = "0.1.5"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bytes 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1362,7 +1406,7 @@ name = "tokio-signal"
 version = "0.1.5"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)",
+ "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.39 (registry+https://github.com/rust-lang/crates.io-index)",
  "mio 0.6.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "mio-uds 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1378,7 +1422,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "error-chain 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
- "futures 0.1.19 (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)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1394,7 +1438,7 @@ version = "0.8.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "error-chain 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
- "futures 0.1.19 (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)",
  "log 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1577,14 +1621,14 @@ dependencies = [
 
 [metadata]
 "checksum actix 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)" = "29d85dc76d055498ef65ecf556df154393f94f55d325a05be20c676432536ce7"
-"checksum actix-web 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)" = "a6477a2dd082fe35e89b3a5b154ac841d0041f786b3d119a8c89776fdca47ae1"
+"checksum actix-web 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "5c6fd8fa3f10cbca9b0050801181e739f045ecd47f3ebeacb150ef7cb81f5ab1"
 "checksum actix_derive 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c4b1dc922654b9aca7a8a31eab875fde804fa9fbd67f220f2e457787b23590f2"
 "checksum aho-corasick 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)" = "d6531d44de723825aa81398a6415283229725a00fa30713812ab9323faa82fc4"
 "checksum arrayref 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "0fd1479b7c29641adbd35ff3b5c293922d696a92f25c8c975da3e0acbc87258f"
 "checksum arrayvec 0.4.7 (registry+https://github.com/rust-lang/crates.io-index)" = "a1e964f9e24d588183fcb43503abda40d288c8657dfc27311516ce2f05675aef"
-"checksum askama 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f7a512bda67cd1fec46d53a2bf9d8a152230357a1e2c56d6467f9b6b4c5265bb"
-"checksum askama_derive 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d832e1c03d4ea2dee7358380d806f5487327b2ca833d1a250a9d8b3b1ce3f5ba"
-"checksum askama_shared 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d722d31c71ed727ade159d64aab7019be0df6363338e83c4751ac5af1730c562"
+"checksum askama 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "59de9ed5a107940d4f4e3230bf4125c08479029d25ce9bd8f494d7664f97e246"
+"checksum askama_derive 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2e667ffc6130c85fddc7cfabe30a7305184988d89dcef173145a0f2395fb2107"
+"checksum askama_shared 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "ab231846f7f9fd8ed036e411e2b43e0de0c29033ef09d109f2e7224d17113e43"
 "checksum backtrace 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "346d7644f0b5f9bc73082d3b2236b69a05fd35cce0cfa3724e184e6a5c9e2a2f"
 "checksum backtrace 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)" = "ebbbf59b1c43eefa8c3ede390fcc36820b4999f7914104015be25025e0d62af2"
 "checksum backtrace-sys 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)" = "44585761d6161b0f57afc49482ab6bd067e4edef48c12a152c237eb0203f7661"
@@ -1611,8 +1655,8 @@ dependencies = [
 "checksum crossbeam-utils 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "2760899e32a1d58d5abb31129f8fae5de75220bc2176e77ff7c627ae45c918d9"
 "checksum crypto-mac 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "0999b4ff4d3446d4ddb19a63e9e00c1876e75cd7000d20e57a693b4b3f08d958"
 "checksum dbghelp-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "97590ba53bcb8ac28279161ca943a924d1fd4a8fb3fa63302591647c4fc5b850"
-"checksum diesel 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "925325c57038f2f14c0413bdf6a92ca72acff644959d0a1a9ebf8d19be7e9c01"
-"checksum diesel_derives 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "28e2b2605ac6a3b9a586383f5f8b2b5f1108f07a421ade965b266289d2805e79"
+"checksum diesel 1.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "24815a0c2094f2c8dafe74ab3b9e975892f44acbb94b4d4b4898025a7615efa4"
+"checksum diesel_derives 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "6471a2b637b414d3ee1504cf230409a550381c79204282f8fe06c527e4ae56be"
 "checksum digest 0.7.2 (registry+https://github.com/rust-lang/crates.io-index)" = "00a49051fef47a72c9623101b19bd71924a45cca838826caae3eaa4d00772603"
 "checksum dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "09c3753c3db574d215cba4ea76018483895d7bff25a31b49ba45db21c48e50ab"
 "checksum encoding 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)" = "6b0d943856b990d12d3b55b359144ff341533e516d94098b1d3fc1ac666d36ec"
@@ -1633,7 +1677,7 @@ dependencies = [
 "checksum fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "2fad85553e09a6f881f739c29f0b00b0f01357c743266d478b68951ce23285f3"
 "checksum fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "2e9763c69ebaae630ba35f74888db465e49e259ba1bc0eda7d06f4a067615d82"
 "checksum fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3dcaa9ae7725d12cdb85b3ad99a434db70b468c09ded17e012d86b5c1010f7a7"
-"checksum futures 0.1.19 (registry+https://github.com/rust-lang/crates.io-index)" = "83f32b9e9aaa890fe8b9453b27ebbf3d11136a5ce59032500effd0e707bbcd80"
+"checksum futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)" = "1a70b146671de62ec8c8ed572219ca5d594d9b06c0b364d5e67b722fc559b48c"
 "checksum futures-cpupool 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "ab90cde24b3319636588d0c35fe03b1333857621051837ed769faefb4c2162e4"
 "checksum gcc 0.3.54 (registry+https://github.com/rust-lang/crates.io-index)" = "5e33ec290da0d127825013597dbdfc28bee4964690c7ce1166cbc2a7bd08b1bb"
 "checksum generic-array 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ef25c5683767570c2bbd7deba372926a55eaae9982d7726ee2a1050239d45b9d"
@@ -1649,6 +1693,7 @@ dependencies = [
 "checksum indexmap 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7b9378f1f3923647a9aea6af4c6b5de68cc8a71415459ad25ef191191c48f5b7"
 "checksum iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "dbe6e417e7d0975db6512b90796e8ce223145ac4e33c377e4a42882a0e88bb08"
 "checksum ipconfig 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "9ec4e18c0a0d4340870c14284293632d8421f419008371422dd327892b88877c"
+"checksum itoa 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "8324a32baf01e2ae060e9de58ed0bc2320c9a2833491ee36cd3b4c414de4db8c"
 "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"
@@ -1689,10 +1734,12 @@ dependencies = [
 "checksum postgres-shared 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "bafecadf25b7de9a5f747e93073db444c9ddcc7b3ae37bcdf63c2508f9a17f2d"
 "checksum pq-sys 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "4dfb5e575ef93a1b7b2a381d47ba7c5d4e4f73bff37cee932195de769aad9a54"
 "checksum proc-macro2 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "cd07deb3c6d1d9ff827999c7f9b04cdfd66b1b17ae508e14fe47b620f2282ae0"
+"checksum proc-macro2 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "49b6a521dc81b643e9a51e0d1cf05df46d5a2f3c0280ea72bcb68276ba64a118"
 "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 quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6e920b65c65f10b2ae65c831a81a073a89edd28c7cce89475bff467ab4167a"
 "checksum quote 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "1eca14c727ad12702eb4b6bfb5a232287dcf8385cb8ca83a3eeaf6519c44c408"
+"checksum quote 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7b0ff51282f28dc1b53fd154298feaa2e77c5ea0dba68e1fd8b03b72fbe13d2a"
 "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 rayon 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)" = "b614fe08b6665cb9a231d07ac1364b0ef3cb3698f1239ee0c4c3a88a524f54c8"
@@ -1714,6 +1761,7 @@ dependencies = [
 "checksum serde_derive 1.0.34 (registry+https://github.com/rust-lang/crates.io-index)" = "86daebd995aa948b069d886f2105f2425cd66103049855e45c15c58c573f12c5"
 "checksum serde_derive_internals 0.22.0 (registry+https://github.com/rust-lang/crates.io-index)" = "6b3f714f52a41e371c5e141e9dafcead60921349bec76b44d79000c88aba3cfc"
 "checksum serde_json 1.0.13 (registry+https://github.com/rust-lang/crates.io-index)" = "5c508584d9913df116b91505eec55610a2f5b16e9ed793c46e4d0152872b3e74"
+"checksum serde_urlencoded 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "ce0fd303af908732989354c6f02e05e2e6d597152870f2c6990efb0577137480"
 "checksum sha1 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "2579985fda508104f7587689507983eadd6a6e84dd35d6d115361f530916fa0d"
 "checksum sha2 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7daca11f2fdb8559c4f6c588386bed5e2ad4b6605c1442935a7f08144a918688"
 "checksum siphasher 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "0df90a788073e8d0235a67e50441d47db7c8ad9debd91cbf43736a2a92d36537"
@@ -1726,6 +1774,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.12.14 (registry+https://github.com/rust-lang/crates.io-index)" = "8c5bc2d6ff27891209efa5f63e9de78648d7801f085e4653701a692ce938d6fd"
+"checksum syn 0.13.1 (registry+https://github.com/rust-lang/crates.io-index)" = "91b52877572087400e83d24b9178488541e3d535259e04ff17a63df1e5ceff59"
 "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"

+ 5 - 5
frameworks/Rust/actix/Cargo.toml

@@ -1,6 +1,6 @@
 [package]
 name = "actix"
-version = "0.3.0"
+version = "0.4.0"
 build = "build.rs"
 
 [[bin]]
@@ -16,7 +16,7 @@ name = "actix-pg"
 path = "src/pg.rs"
 
 [dependencies]
-askama = "0.5"
+askama = "0.6"
 serde = "1.0"
 serde_json = "1.0"
 serde_derive = "1.0"
@@ -27,14 +27,14 @@ futures = "0.1"
 tokio-io = "=0.1.5"
 tokio-core = "=0.1.12"
 http = "0.1"
-diesel = { version = "1.1", features = ["postgres"] }
+diesel = { version = "1.2", features = ["postgres"] }
 postgres = "0.15"
 
 actix = "0.5"
-actix-web = "^0.4.10"
+actix-web = "^0.5"
 
 [build-dependencies]
-askama = "0.5"
+askama = "0.6"
 
 [profile.release]
 lto = true

+ 33 - 33
frameworks/Rust/actix/src/main.rs

@@ -1,6 +1,5 @@
 extern crate actix;
 extern crate actix_web;
-extern crate http;
 extern crate bytes;
 extern crate rand;
 extern crate num_cpus;
@@ -12,13 +11,14 @@ extern crate serde_json;
 #[macro_use] extern crate askama;
 
 use std::cmp;
-use actix_web::*;
 use actix::prelude::*;
 use bytes::BytesMut;
 use askama::Template;
-use http::header;
 use futures::Future;
 use diesel::prelude::{Connection, PgConnection};
+use actix_web::{
+    http, server,
+    App, HttpRequest, HttpResponse, FutureResponse, AsyncResponder};
 
 mod db;
 mod schema;
@@ -30,27 +30,27 @@ struct State {
     db: Addr<Syn, db::DbExecutor>
 }
 
-fn world_row(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error>> {
-    req.state().db.send(db::RandomWorld)
+fn world_row(req: HttpRequest<State>) -> FutureResponse<HttpResponse> {
+    req.clone().state().db.send(db::RandomWorld)
         .from_err()
-        .and_then(|res| {
+        .and_then(move |res| {
             match res {
                 Ok(row) => {
                     let mut body = BytesMut::with_capacity(31);
                     serde_json::to_writer(Writer(&mut body), &row).unwrap();
-                    Ok(httpcodes::HTTPOk.build()
-                       .header(header::SERVER, "Actix")
+                    Ok(HttpResponse::build_from(&req)
+                       .header(http::header::SERVER, "Actix")
                        .content_type("application/json")
-                       .body(body.freeze())?)
+                       .body(body))
                 },
                 Err(_) =>
-                    Ok(httpcodes::HTTPInternalServerError.into()),
+                    Ok(HttpResponse::InternalServerError().into()),
             }
         })
         .responder()
 }
 
-fn queries(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error>> {
+fn queries(req: HttpRequest<State>) -> FutureResponse<HttpResponse> {
     // get queries parameter
     let q = if let Some(q) = req.query().get("q") {
         q.parse::<u16>().ok().unwrap_or(1)
@@ -60,24 +60,24 @@ fn queries(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error
     let q = cmp::min(500, cmp::max(1, q));
 
     // run sql queries
-    req.state().db.send(db::RandomWorlds(q))
+    req.clone().state().db.send(db::RandomWorlds(q))
         .from_err()
-        .and_then(|res| {
+        .and_then(move |res| {
             if let Ok(worlds) = res {
                 let mut body = BytesMut::with_capacity(35 * worlds.len());
                 serde_json::to_writer(Writer(&mut body), &worlds).unwrap();
-                Ok(httpcodes::HTTPOk.build()
-                   .header(header::SERVER, "Actix")
+                Ok(HttpResponse::build_from(&req)
+                   .header(http::header::SERVER, "Actix")
                    .content_type("application/json")
-                   .body(body.freeze())?)
+                   .body(body))
             } else {
-                Ok(httpcodes::HTTPInternalServerError.into())
+                Ok(HttpResponse::InternalServerError().into())
             }
         })
         .responder()
 }
 
-fn updates(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error>> {
+fn updates(req: HttpRequest<State>) -> FutureResponse<HttpResponse> {
     // get queries parameter
     let q = if let Some(q) = req.query().get("q") {
         q.parse::<usize>().ok().unwrap_or(1)
@@ -87,18 +87,18 @@ fn updates(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error
     let q = cmp::min(500, cmp::max(1, q));
 
     // update worlds
-    req.state().db.send(db::UpdateWorld(q))
+    req.clone().state().db.send(db::UpdateWorld(q))
         .from_err()
         .and_then(move |res| {
             if let Ok(worlds) = res {
                 let mut body = BytesMut::with_capacity(35 * worlds.len());
                 serde_json::to_writer(Writer(&mut body), &worlds).unwrap();
-                Ok(httpcodes::HTTPOk.build()
-                   .header(header::SERVER, "Actix")
+                Ok(HttpResponse::build_from(&req)
+                   .header(http::header::SERVER, "Actix")
                    .content_type("application/json")
-                   .body(body)?)
+                   .body(body))
             } else {
-                Ok(httpcodes::HTTPInternalServerError.into())
+                Ok(HttpResponse::InternalServerError().into())
             }
         })
         .responder()
@@ -110,23 +110,22 @@ struct FortuneTemplate<'a> {
     items: &'a Vec<models::Fortune>,
 }
 
-fn fortune(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error>> {
-    req.state().db.send(db::TellFortune)
+fn fortune(req: HttpRequest<State>) -> FutureResponse<HttpResponse> {
+    req.clone().state().db.send(db::TellFortune)
         .from_err()
-        .and_then(|res| {
+        .and_then(move |res| {
             match res {
                 Ok(rows) => {
                     let tmpl = FortuneTemplate { items: &rows };
                     let res = tmpl.render().unwrap();
 
-                    Ok(httpcodes::HTTPOk.build()
-                       .header(header::SERVER, "Actix")
+                    Ok(HttpResponse::build_from(&req)
+                       .header(http::header::SERVER, "Actix")
                        .content_type("text/html; charset=utf-8")
-                       .content_encoding(headers::ContentEncoding::Identity)
-                       .body(res)?)
+                       .body(res))
                 },
                 Err(_) => {
-                    Ok(httpcodes::HTTPInternalServerError.into())
+                    Ok(HttpResponse::InternalServerError().into())
                 }
             }
         })
@@ -149,8 +148,9 @@ fn main() {
         num_cpus::get() * 4, move || db::DbExecutor::new(db_url));
 
     // start http server
-    HttpServer::new(
-        move || Application::with_state(State{db: addr.clone()})
+    server::new(
+        move || App::with_state(State{db: addr.clone()})
+            .default_encoding(http::ContentEncoding::Identity)
             .resource("/db", |r| r.route().a(world_row))
             .resource("/fortune", |r| r.route().a(fortune))
             .resource("/queries", |r| r.route().a(queries))

+ 30 - 31
frameworks/Rust/actix/src/pg.rs

@@ -1,6 +1,5 @@
 extern crate actix;
 extern crate actix_web;
-extern crate http;
 extern crate bytes;
 extern crate rand;
 extern crate num_cpus;
@@ -12,14 +11,14 @@ extern crate serde_json;
 #[macro_use] extern crate askama;
 
 use std::{io, cmp};
-use actix_web::*;
 use actix::prelude::*;
 use askama::Template;
-use http::header;
 use bytes::BytesMut;
 use postgres::{Connection, TlsMode};
 use rand::{thread_rng, Rng, ThreadRng};
 use futures::Future;
+use actix_web::{
+    http, server, App, HttpRequest, HttpResponse, FutureResponse, AsyncResponder};
 
 mod utils;
 use utils::Writer;
@@ -42,26 +41,26 @@ struct State {
     db: Addr<Syn, PgConnection>
 }
 
-fn world_row(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error>> {
-    req.state().db.send(RandomWorld)
+fn world_row(req: HttpRequest<State>) -> FutureResponse<HttpResponse> {
+    req.clone().state().db.send(RandomWorld)
         .from_err()
-        .and_then(|res| {
+        .and_then(move |res| {
             match res {
                 Ok(row) => {
                     let mut body = BytesMut::with_capacity(31);
                     serde_json::to_writer(Writer(&mut body), &row).unwrap();
-                    Ok(httpcodes::HTTPOk.build()
-                       .header(header::SERVER, "Actix")
+                    Ok(HttpResponse::build_from(&req)
+                       .header(http::header::SERVER, "Actix")
                        .content_type("application/json")
-                       .body(body)?)
+                       .body(body))
                 },
-                Err(_) => Ok(httpcodes::HTTPInternalServerError.into()),
+                Err(_) => Ok(HttpResponse::InternalServerError().into()),
             }
         })
         .responder()
 }
 
-fn queries(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error>> {
+fn queries(req: HttpRequest<State>) -> FutureResponse<HttpResponse> {
     // get queries parameter
     let q = if let Some(q) = req.query().get("q") {
         q.parse::<u16>().ok().unwrap_or(1)
@@ -71,24 +70,24 @@ fn queries(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error
     let q = cmp::min(500, cmp::max(1, q));
 
     // run sql queries
-    req.state().db.send(RandomWorlds(q))
+    req.clone().state().db.send(RandomWorlds(q))
         .from_err()
-        .and_then(|res| {
+        .and_then(move |res| {
             if let Ok(worlds) = res {
                 let mut body = BytesMut::with_capacity(35 * worlds.len());
                 serde_json::to_writer(Writer(&mut body), &worlds).unwrap();
-                Ok(httpcodes::HTTPOk.build()
-                   .header(header::SERVER, "Actix")
+                Ok(HttpResponse::build_from(&req)
+                   .header(http::header::SERVER, "Actix")
                    .content_type("application/json")
-                   .body(body)?)
+                   .body(body))
             } else {
-                Ok(httpcodes::HTTPInternalServerError.into())
+                Ok(HttpResponse::InternalServerError().into())
             }
         })
         .responder()
 }
 
-fn updates(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error>> {
+fn updates(req: HttpRequest<State>) -> FutureResponse<HttpResponse> {
     // get queries parameter
     let q = if let Some(q) = req.query().get("q") {
         q.parse::<u16>().ok().unwrap_or(1)
@@ -98,18 +97,18 @@ fn updates(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error
     let q = cmp::min(500, cmp::max(1, q));
 
     // update db
-    req.state().db.send(UpdateWorld(q))
+    req.clone().state().db.send(UpdateWorld(q))
         .from_err()
         .and_then(move |res| {
             if let Ok(worlds) = res {
                 let mut body = BytesMut::with_capacity(35 * worlds.len());
                 serde_json::to_writer(Writer(&mut body), &worlds).unwrap();
-                Ok(httpcodes::HTTPOk.build()
-                   .header(header::SERVER, "Actix")
+                Ok(HttpResponse::build_from(&req)
+                   .header(http::header::SERVER, "Actix")
                    .content_type("application/json")
-                   .body(body)?)
+                   .body(body))
             } else {
-                Ok(httpcodes::HTTPInternalServerError.into())
+                Ok(HttpResponse::InternalServerError().into())
             }
         })
         .responder()
@@ -121,7 +120,7 @@ struct FortuneTemplate<'a> {
     items: &'a Vec<Fortune>,
 }
 
-fn fortune(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error>> {
+fn fortune(req: HttpRequest<State>) -> FutureResponse<HttpResponse> {
     req.state().db.send(TellFortune)
         .from_err()
         .and_then(|res| {
@@ -130,13 +129,12 @@ fn fortune(req: HttpRequest<State>) -> Box<Future<Item=HttpResponse, Error=Error
                     let tmpl = FortuneTemplate { items: &rows };
                     let res = tmpl.render().unwrap();
 
-                    Ok(httpcodes::HTTPOk.build()
-                       .header(header::SERVER, "Actix")
+                    Ok(HttpResponse::Ok()
+                       .header(http::header::SERVER, "Actix")
                        .content_type("text/html; charset=utf-8")
-                       .content_encoding(headers::ContentEncoding::Identity)
-                       .body(res)?)
+                       .body(res))
                 },
-                Err(_) => Ok(httpcodes::HTTPInternalServerError.into())
+                Err(_) => Ok(HttpResponse::InternalServerError().into())
             }
         })
         .responder()
@@ -288,8 +286,9 @@ fn main() {
         num_cpus::get() * 4, move || PgConnection::new(db_url));
 
     // start http server
-    HttpServer::new(
-        move || Application::with_state(State{db: addr.clone()})
+    server::new(
+        move || App::with_state(State{db: addr.clone()})
+            .default_encoding(http::ContentEncoding::Identity)
             .resource("/db", |r| r.route().a(world_row))
             .resource("/queries", |r| r.route().a(queries))
             .resource("/fortune", |r| r.route().a(fortune))

+ 15 - 21
frameworks/Rust/actix/src/simple.rs

@@ -1,17 +1,14 @@
 extern crate actix;
 extern crate actix_web;
 extern crate bytes;
-extern crate http;
 extern crate futures;
 extern crate serde;
 extern crate serde_json;
 #[macro_use] extern crate serde_derive;
 
-use actix_web::*;
-use actix::prelude::*;
 use bytes::BytesMut;
-use http::StatusCode;
-use http::header::{self, HeaderValue};
+use actix::prelude::*;
+use actix_web::{http, server, App, HttpRequest, HttpResponse};
 
 mod utils;
 use utils::Writer;
@@ -23,39 +20,36 @@ pub struct Message {
     pub message: &'static str,
 }
 
-fn json(_: HttpRequest) -> HttpResponse {
+fn json(req: HttpRequest) -> HttpResponse {
     let message = Message {
         message: "Hello, World!"
     };
     let mut body = BytesMut::with_capacity(SIZE);
     serde_json::to_writer(Writer(&mut body), &message).unwrap();
 
-    let mut resp = HttpResponse::new(StatusCode::OK, body.into());
-    resp.headers_mut().insert(
-        header::SERVER, HeaderValue::from_static("Actix"));
-    resp.headers_mut().insert(
-        header::CONTENT_TYPE, HeaderValue::from_static("application/json"));
-    resp
+    HttpResponse::build_from(&req)
+        .header(http::header::SERVER, "Actix")
+        .header(http::header::CONTENT_TYPE, "application/json")
+        .body(body)
 }
 
-fn plaintext(_: HttpRequest) -> HttpResponse {
-    let mut resp = HttpResponse::new(StatusCode::OK, "Hello, World!".into());
-    resp.headers_mut().insert(
-        header::SERVER, HeaderValue::from_static("Actix"));
-    resp.headers_mut().insert(
-        header::CONTENT_TYPE, HeaderValue::from_static("text/plain"));
-    resp
+fn plaintext(req: HttpRequest) -> HttpResponse {
+    HttpResponse::build_from(&req)
+        .header(http::header::SERVER, "Actix")
+        .header(http::header::CONTENT_TYPE, "text/plain")
+        .body("Hello, World!")
 }
 
 fn main() {
     let sys = System::new("techempower");
 
     // start http server
-    HttpServer::new(
-        move || Application::new()
+    server::new(
+        move || App::new()
             .resource("/json", |r| r.f(json))
             .resource("/plaintext", |r| r.f(plaintext)))
         .backlog(8192)
+        .threads(1)
         .bind("0.0.0.0:8080").unwrap()
         .start();