Remove actix actor dep from core

This commit is contained in:
asonix 2020-04-23 13:23:09 -05:00
parent ba1a9f422f
commit 57e6a06f00
2 changed files with 4 additions and 4 deletions

View file

@ -1,7 +1,7 @@
[package]
name = "background-jobs-core"
description = "Core types for implementing an asynchronous jobs processor"
version = "0.8.0-alpha.1"
version = "0.8.0-alpha.2"
license-file = "../LICENSE"
authors = ["asonix <asonix@asonix.dog>"]
repository = "https://git.asonix.dog/Aardwolf/background-jobs"
@ -11,10 +11,10 @@ edition = "2018"
[features]
default = []
with-actix = ["actix", "tokio"]
with-actix = ["actix-rt", "tokio"]
[dependencies]
actix = { version = "0.10.0-alpha.2", optional = true }
actix-rt = { version = "1.1.0", optional = true }
anyhow = "1.0"
async-trait = "0.1.24"
chrono = { version = "0.4", features = ["serde"] }

View file

@ -102,7 +102,7 @@ where
fn run(self, state: Self::State) -> Self::Future {
let (tx, rx) = oneshot::channel();
actix::spawn(async move {
actix_rt::spawn(async move {
if let Err(_) = tx.send(ActixJob::run(self, state).await) {
error!("Job dropped");
}