update dependencies
This commit is contained in:
parent
6a4c1f3488
commit
ac7ba66bb3
1345
Cargo.lock
generated
1345
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
|
@ -24,11 +24,11 @@ let
|
|||
in {
|
||||
ticker-update = build {
|
||||
pname = "ticker-update";
|
||||
cargoSha256 = "0g4n8524n2kbn6ln3w98ig3wxss3c5fkbzp1zhwmm95pzcy7n6bm";
|
||||
cargoSha256 = "0ly7z50am7xgqcgghkzxqgi8fx1jmsl5zh32rymnwq1yad5z19nq";
|
||||
};
|
||||
ticker-serve = (build {
|
||||
pname = "ticker-serve";
|
||||
cargoSha256 = "0dxmgrgfjbrhghs148381knns5hy8a2dmc91m81l5zf663x2pwf4";
|
||||
cargoSha256 = "1wqyg7mil35a8d0779yq3w14x7p5ahmfxnmlxx9a0mnfy8jxizb4";
|
||||
}).overrideAttrs (oa: {
|
||||
postBuild = ''
|
||||
${oa.postBuild}
|
||||
|
|
|
@ -6,8 +6,8 @@ edition = "2018"
|
|||
license = "AGPL-3.0-or-later"
|
||||
|
||||
[dependencies]
|
||||
gotham = "0.5"
|
||||
gotham_derive = "0.5"
|
||||
gotham = "~0.7"
|
||||
gotham_derive = "~0.7"
|
||||
http = "0.2"
|
||||
mime = "0.3"
|
||||
typed-html = "0.2"
|
||||
|
|
|
@ -5,11 +5,10 @@ extern crate gotham_derive;
|
|||
|
||||
use std::sync::{Arc, Mutex};
|
||||
use gotham::{
|
||||
handler::assets::FileOptions,
|
||||
handler::FileOptions,
|
||||
router::builder::{DefineSingleRoute, DrawRoutes},
|
||||
middleware::state::StateMiddleware,
|
||||
pipeline::single::single_pipeline,
|
||||
pipeline::single_middleware,
|
||||
pipeline::{single_pipeline, single_middleware},
|
||||
router::builder::*,
|
||||
};
|
||||
use diesel::{Connection, pg::PgConnection};
|
||||
|
@ -48,4 +47,5 @@ fn main() {
|
|||
);
|
||||
});
|
||||
gotham::start("0.0.0.0:8400", router)
|
||||
.unwrap()
|
||||
}
|
||||
|
|
|
@ -6,10 +6,10 @@ edition = "2018"
|
|||
license = "AGPL-3.0-or-later"
|
||||
|
||||
[dependencies]
|
||||
reqwest = "~0.9"
|
||||
reqwest = { version = "~0.11", features = ["blocking"] }
|
||||
diesel = { version = "~1", features = ["postgres", "chrono"] }
|
||||
chrono = "~0.4"
|
||||
num_cpus = "~1"
|
||||
crossbeam = "~0.7"
|
||||
rrule = "0.5"
|
||||
crossbeam = "~0.8"
|
||||
rrule = "0.7"
|
||||
libticker = { path = "../libticker" }
|
||||
|
|
|
@ -83,13 +83,13 @@ fn obj_to_events(calendar: String, obj: &Object) -> Vec<Event> {
|
|||
|
||||
pub struct Resources {
|
||||
db_url: String,
|
||||
http_client: reqwest::Client,
|
||||
http_client: reqwest::blocking::Client,
|
||||
queue: RwLock<VecDeque<(String, CalendarOptions)>>,
|
||||
}
|
||||
|
||||
impl Resources {
|
||||
pub fn new(db_url: String, queue: VecDeque<(String, CalendarOptions)>) -> Self {
|
||||
let http_client = reqwest::Client::new();
|
||||
let http_client = reqwest::blocking::Client::new();
|
||||
let queue = RwLock::new(queue);
|
||||
Resources { db_url, http_client, queue }
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user