1
0
mirror of https://github.com/actix/examples synced 2025-06-28 18:00:37 +02:00

upgrade to beta3

This commit is contained in:
Nikolay Kim
2019-05-04 21:52:24 -07:00
parent d571ee5abb
commit 8de183768c
33 changed files with 70 additions and 80 deletions

View File

@ -83,19 +83,12 @@ fn main() -> std::io::Result<()> {
App::new()
// enable logger
.wrap(middleware::Logger::default())
.data(web::JsonConfig::default().limit(4096)) // <- limit size of the payload (global configuration)
.service(web::resource("/extractor").route(web::post().to(index)))
.service(
web::resource("/extractor").route(
web::post()
.data(web::JsonConfig::default().limit(4096)) // <- limit size of the payload
.to(index),
),
)
.service(
web::resource("/extractor2").route(
web::post()
.data(web::JsonConfig::default().limit(4096)) // <- limit size of the payload
.to_async(extract_item),
),
web::resource("/extractor2")
.data(web::JsonConfig::default().limit(1024)) // <- limit size of the payload (resource level)
.route(web::post().to_async(extract_item)),
)
.service(web::resource("/manual").route(web::post().to_async(index_manual)))
.service(