pub async fn create_messenger_and_publisher(
) -> (MessengerClient<ServicePayload, ServiceAddress, ServiceRole>, Publisher) {
    let message_hub = MessageHub::create_hub();
    let publisher = Publisher::create(&message_hub, MessengerType::Unbound).await;

    let messenger =
        message_hub.create(MessengerType::Unbound).await.expect("Unable to create messenger").0;

    return (messenger, publisher);
}
// Create a messenger hub, returning an unbound messenger and publisher.
Create a messenger hub, returning an unbound messenger and publisher.
Create a messenger hub returning an unbound messenger and publisher .
pub async fn create_messenger_and_publisher(
) -> (MessengerClient<ServicePayload, ServiceAddress, ServiceRole>, Publisher) {
    let message_hub = MessageHub::create_hub();
    let publisher = Publisher::create(&message_hub, MessengerType::Unbound).await;
    let messenger =
        message_hub.create(MessengerType::Unbound).await.expect("Unable to create messenger").0;
    return (messenger, publisher);
}
pub async fn create_messenger_and_publisher ( ) -> ( MessengerClient < ServicePayload , ServiceAddress , ServiceRole > , Publisher ) { let message_hub = MessageHub :: create_hub ( ) ; let publisher = Publisher :: create ( & message_hub , MessengerType :: Unbound ) . await ; let messenger = message_hub . create ( MessengerType :: Unbound ) . await . expect ( " " ) . 0 ; return ( messenger , publisher ) ; }
Create a messenger hub, returning an unbound messenger and publisher.
Create a messenger hub returning an unbound messenger and publisher .