pub enum WireFmt {
Uncompressed,
ByteBuffer,
}
Expand description
Wire formats. Default is Uncompressed.
- Uncompressed, the entire payload is a string, formatted as:
format!("{} {:<5} [{}] {}",
Utc::now().format("%Y-%m-%d %H:%M:%S%.3f"),
record.level().to_string(),
target,
record.args()
);
and has kv pairs, appended, as:
format!(" {}={}", k, v);
- ByteBuffer, the entire payload is a u8 level, i64 Utc::now().timestamp_millis(), and u32 string length followed by length * utf8.
Variants§
Uncompressed
No Compression, the payload can be consistered a string of utf8 bytes.
ByteBuffer
1 byte Level, 8 bytes timestamp, 4 bytes len followed by len * utf8 (string)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for WireFmt
impl RefUnwindSafe for WireFmt
impl Send for WireFmt
impl Sync for WireFmt
impl Unpin for WireFmt
impl UnwindSafe for WireFmt
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