diff --git a/CHANGES.md b/CHANGES.md index 54c5bb06c..281879685 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,6 +1,6 @@ # Changes -## [2.0.0] - 2019-12-xx +## [2.0.0-rc] - 2019-12-20 ### Changed diff --git a/Cargo.toml b/Cargo.toml index 0fab5d58c..aba3c6546 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "actix-web" -version = "2.0.0-alpha.6" +version = "2.0.0-rc" authors = ["Nikolay Kim "] description = "Actix web is a simple, pragmatic and extremely fast web framework for Rust." readme = "README.md" diff --git a/actix-cors/Cargo.toml b/actix-cors/Cargo.toml index 05885acfd..392168e42 100644 --- a/actix-cors/Cargo.toml +++ b/actix-cors/Cargo.toml @@ -17,7 +17,7 @@ name = "actix_cors" path = "src/lib.rs" [dependencies] -actix-web = "2.0.0-alpha.5" +actix-web = "2.0.0-rc" actix-service = "1.0.0" derive_more = "0.99.2" futures = "0.3.1" diff --git a/actix-files/Cargo.toml b/actix-files/Cargo.toml index 3eecdbabe..7f11605a1 100644 --- a/actix-files/Cargo.toml +++ b/actix-files/Cargo.toml @@ -18,8 +18,8 @@ name = "actix_files" path = "src/lib.rs" [dependencies] -actix-web = { version = "2.0.0-alpha.6", default-features = false } -actix-http = "1.0.0" +actix-web = { version = "2.0.0-rc", default-features = false } +actix-http = "1.0.1" actix-service = "1.0.0" bitflags = "1" bytes = "0.5.3" @@ -33,4 +33,4 @@ v_htmlescape = "0.4" [dev-dependencies] actix-rt = "1.0.0" -actix-web = { version = "2.0.0-alpha.6", features=["openssl"] } +actix-web = { version = "2.0.0-rc", features=["openssl"] } diff --git a/actix-identity/Cargo.toml b/actix-identity/Cargo.toml index 4e96203bf..a5058b8cd 100644 --- a/actix-identity/Cargo.toml +++ b/actix-identity/Cargo.toml @@ -17,7 +17,7 @@ name = "actix_identity" path = "src/lib.rs" [dependencies] -actix-web = { version = "2.0.0-alpha.5", default-features = false, features = ["secure-cookies"] } +actix-web = { version = "2.0.0-rc", default-features = false, features = ["secure-cookies"] } actix-service = "1.0.0" futures = "0.3.1" serde = "1.0" @@ -26,5 +26,5 @@ time = "0.1.42" [dev-dependencies] actix-rt = "1.0.0" -actix-http = "1.0.0" +actix-http = "1.0.1" bytes = "0.5.3" \ No newline at end of file diff --git a/actix-multipart/Cargo.toml b/actix-multipart/Cargo.toml index b0ef36d10..bbf83ed00 100644 --- a/actix-multipart/Cargo.toml +++ b/actix-multipart/Cargo.toml @@ -16,7 +16,7 @@ name = "actix_multipart" path = "src/lib.rs" [dependencies] -actix-web = { version = "2.0.0-alpha.5", default-features = false } +actix-web = { version = "2.0.0-rc", default-features = false } actix-service = "1.0.0" actix-utils = "1.0.3" bytes = "0.5.3" diff --git a/actix-session/Cargo.toml b/actix-session/Cargo.toml index f26401851..ed80174ff 100644 --- a/actix-session/Cargo.toml +++ b/actix-session/Cargo.toml @@ -22,7 +22,7 @@ default = ["cookie-session"] cookie-session = ["actix-web/secure-cookies"] [dependencies] -actix-web = "2.0.0-alpha.5" +actix-web = "2.0.0-rc" actix-service = "1.0.0" bytes = "0.5.3" derive_more = "0.99.2" diff --git a/actix-web-actors/Cargo.toml b/actix-web-actors/Cargo.toml index d4fe45363..6f573e442 100644 --- a/actix-web-actors/Cargo.toml +++ b/actix-web-actors/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "actix-web-actors" -version = "2.0.0-alpha.1" +version = "2.0.0" authors = ["Nikolay Kim "] description = "Actix actors support for actix web framework." readme = "README.md" @@ -16,9 +16,9 @@ name = "actix_web_actors" path = "src/lib.rs" [dependencies] -actix = "0.9.0-alpha.1" -actix-web = "2.0.0-alpha.5" -actix-http = "1.0.0" +actix = "0.9.0" +actix-web = "2.0.0-rc" +actix-http = "1.0.1" actix-codec = "0.2.0" bytes = "0.5.2" futures = "0.3.1" diff --git a/actix-web-codegen/Cargo.toml b/actix-web-codegen/Cargo.toml index 71facfe9d..3fe561deb 100644 --- a/actix-web-codegen/Cargo.toml +++ b/actix-web-codegen/Cargo.toml @@ -18,5 +18,5 @@ proc-macro2 = "^1" [dev-dependencies] actix-rt = { version = "1.0.0" } -actix-web = { version = "2.0.0-alpha.4" } +actix-web = { version = "2.0.0-rc" } futures = { version = "0.3.1" } diff --git a/awc/Cargo.toml b/awc/Cargo.toml index d1eaa7f69..723cd59de 100644 --- a/awc/Cargo.toml +++ b/awc/Cargo.toml @@ -55,8 +55,8 @@ rust-tls = { version = "0.16.0", package="rustls", optional = true, features = [ [dev-dependencies] actix-connect = { version = "1.0.1", features=["openssl"] } -actix-web = { version = "2.0.0-alpha.5", features=["openssl"] } -actix-http = { version = "1.0.0", features=["openssl"] } +actix-web = { version = "2.0.0-rc", features=["openssl"] } +actix-http = { version = "1.0.1", features=["openssl"] } actix-http-test = { version = "1.0.0", features=["openssl"] } actix-utils = "1.0.3" actix-server = "1.0.0" diff --git a/awc/tests/test_rustls_client.rs b/awc/tests/test_rustls_client.rs index 5da5c1899..68acf7f71 100644 --- a/awc/tests/test_rustls_client.rs +++ b/awc/tests/test_rustls_client.rs @@ -4,9 +4,9 @@ use std::sync::Arc; use actix_http::HttpService; use actix_http_test::test_server; -use actix_service::{map_config, pipeline_factory, ServiceFactory, IntoServiceFactory}; +use actix_service::{map_config, pipeline_factory, IntoServiceFactory, ServiceFactory}; use actix_web::http::Version; -use actix_web::{web, App, HttpResponse, dev::AppConfig}; +use actix_web::{dev::AppConfig, web, App, HttpResponse}; use futures::future::ok; use open_ssl::ssl::{SslAcceptor, SslFiletype, SslMethod, SslVerifyMode}; use rust_tls::ClientConfig; @@ -62,10 +62,13 @@ async fn _test_connection_reuse_h2() { }) .and_then( HttpService::build() - .h2(map_config(App::new() - .service(web::resource("/").route(web::to(|| HttpResponse::Ok()))) - .into_factory(), - |_| AppConfig::default(), + .h2(map_config( + App::new() + .service( + web::resource("/").route(web::to(|| HttpResponse::Ok())), + ) + .into_factory(), + |_| AppConfig::default(), )) .openssl(ssl_acceptor()) .map_err(|_| ()), diff --git a/src/app.rs b/src/app.rs index 962ff4b47..a060eb53e 100644 --- a/src/app.rs +++ b/src/app.rs @@ -78,8 +78,9 @@ where /// an application instance. Http server constructs an application /// instance for each thread, thus application data must be constructed /// multiple times. If you want to share data between different - /// threads, a shared object should be used, e.g. `Arc`. Application - /// data does not need to be `Send` or `Sync`. + /// threads, a shared object should be used, e.g. `Arc`. Internally `Data` type + /// uses `Arc` so data could be created outside of app factory and clones could + /// be stored via `App::app_data()` method. /// /// ```rust /// use std::cell::Cell; diff --git a/test-server/Cargo.toml b/test-server/Cargo.toml index a6173088a..54cd01686 100644 --- a/test-server/Cargo.toml +++ b/test-server/Cargo.toml @@ -55,5 +55,5 @@ time = "0.1" open-ssl = { version="0.10", package="openssl", optional = true } [dev-dependencies] -actix-web = "2.0.0-alpha.5" -actix-http = "1.0.0" +actix-web = "2.0.0-rc" +actix-http = "1.0.1"