rename queue function
This commit is contained in:
parent
e731ba1426
commit
68ce2192a1
3 changed files with 7 additions and 7 deletions
|
@ -6,4 +6,4 @@ pub(crate) mod reqwest_shim;
|
|||
pub(crate) mod traits;
|
||||
|
||||
/// Mime type for Activitypub data, used for `Accept` and `Content-Type` HTTP headers
|
||||
pub static FEDERATION_CONTENT_TYPE: &str = "application/activity+json";
|
||||
pub(crate) static FEDERATION_CONTENT_TYPE: &str = "application/activity+json";
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
mod error;
|
||||
mod federation;
|
||||
mod queue;
|
||||
pub mod error;
|
||||
pub(crate) mod federation;
|
||||
pub mod queue;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
//! Used to queue inbox and outbox tasks
|
||||
//! Used to queue sending activity
|
||||
|
||||
use crate::{
|
||||
error::Error,
|
||||
|
@ -39,7 +39,7 @@ pub struct SendActivityTask {
|
|||
pub trait QueueManager: DynClone + Send {
|
||||
/// Called in [crate::queue::send_activity], and would call
|
||||
/// [crate::queue::do_send] inside to send activity to remote servers.
|
||||
async fn queue_send(&self, task: SendActivityTask) -> Result<(), Error>;
|
||||
async fn queue_deliver(&self, task: SendActivityTask) -> Result<(), Error>;
|
||||
}
|
||||
|
||||
clone_trait_object!(QueueManager);
|
||||
|
@ -96,7 +96,7 @@ where
|
|||
}
|
||||
} else {
|
||||
debug!(task = ?message, "Queue sending activity");
|
||||
data.config.queue_manager.queue_send(message).await?;
|
||||
data.config.queue_manager.queue_deliver(message).await?;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue