pub enum NatsAuth {
Anonymous,
CredentialsFile(PathBuf),
NKeySeed(String),
UserPassword {
user: String,
password: String,
},
}Expand description
How a component authenticates to NATS: NATS_CREDS_FILE (a .creds
file), NATS_NKEY_SEED, or NATS_USER with NATS_PASSWORD; at most one.
Without any the connection is anonymous, as before.
Variants§
Implementations§
Trait Implementations§
impl Eq for NatsAuth
impl StructuralPartialEq for NatsAuth
Auto Trait Implementations§
impl Freeze for NatsAuth
impl RefUnwindSafe for NatsAuth
impl Send for NatsAuth
impl Sync for NatsAuth
impl Unpin for NatsAuth
impl UnsafeUnpin for NatsAuth
impl UnwindSafe for NatsAuth
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