pub struct ClientConfig {
pub identity: ServiceIdentity,
pub target: ConnectionTarget,
pub client_id: Option<String>,
pub channel_capacity: usize,
pub keep_alive: Duration,
}Expand description
Configuration for creating a Client.
Fields§
§identity: ServiceIdentity§target: ConnectionTarget§client_id: Option<String>MQTT client ID. Defaults to "{service}-{instance_id}".
channel_capacity: usizeChannel capacity for the internal event loop. Default: 128.
keep_alive: DurationKeep-alive interval (remote only). Default: 30s.
Implementations§
Source§impl ClientConfig
impl ClientConfig
pub fn new(identity: ServiceIdentity, target: ConnectionTarget) -> Self
Auto Trait Implementations§
impl Freeze for ClientConfig
impl RefUnwindSafe for ClientConfig
impl Send for ClientConfig
impl Sync for ClientConfig
impl Unpin for ClientConfig
impl UnsafeUnpin for ClientConfig
impl UnwindSafe for ClientConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more