Browse Source

Move pub/sub to it's own module

master
Alex Mikhalev 4 years ago
parent
commit
ec49c28425
  1. 6
      src/lib.rs
  2. 5
      src/pub_sub/mod.rs
  3. 0
      src/pub_sub/publication.rs
  4. 0
      src/pub_sub/subscription.rs

6
src/lib.rs

@ -1,14 +1,12 @@ @@ -1,14 +1,12 @@
mod broker_task;
mod message;
mod publication;
mod subscription;
mod pub_sub;
use broker_task::{
AdvertiseRequest, BrokerError, BrokerRequestSender, BrokerResult, BrokerTask, SubscribeRequest,
};
pub use message::Message;
pub use publication::{Publication, PublishError};
pub use subscription::{Subscription, SubscriptionError};
pub use pub_sub::*;
use futures::executor::block_on;
use tokio::sync::oneshot;

5
src/pub_sub/mod.rs

@ -0,0 +1,5 @@ @@ -0,0 +1,5 @@
mod publication;
mod subscription;
pub use publication::{Publication, PublishError};
pub use subscription::{Subscription, SubscriptionError};

0
src/publication.rs → src/pub_sub/publication.rs

0
src/subscription.rs → src/pub_sub/subscription.rs

Loading…
Cancel
Save