Skip to main content

MessageBusBackingFactory

Trait MessageBusBackingFactory 

Source
pub trait MessageBusBackingFactory:
    Debug
    + Send
    + Sync {
    // Required method
    fn create(
        &self,
        trader_id: TraderId,
        instance_id: UUID4,
        config: MessageBusConfig,
    ) -> Result<Box<dyn MessageBusBacking>>;
}
Expand description

Factory for constructing external message bus backings.

Implementations own concrete backing configuration and return the MessageBusBacking surface used by the core bus runtime.

Required Methods§

Source

fn create( &self, trader_id: TraderId, instance_id: UUID4, config: MessageBusConfig, ) -> Result<Box<dyn MessageBusBacking>>

Creates a message bus backing for the given bus runtime.

§Errors

Returns an error if backing construction or connection setup fails.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§