pub struct Log;Expand description
Logging helpers for access logs and server info.
Log::combined produces standard Combined Log Format lines compatible with
GoAccess, AWStats, and similar tools. All three server code paths (HTTP/1.1,
HTTP/2, HTTP/3) use it.
Implementations§
Source§impl Log
impl Log
pub fn request_response( request: &Request, response: &Response, peer_addr: &SocketAddr, ) -> String
pub fn usage_information() -> String
pub fn info(name: &str) -> String
Sourcepub fn combined(
request: &Request,
response: &Response,
peer_addr: &SocketAddr,
) -> String
pub fn combined( request: &Request, response: &Response, peer_addr: &SocketAddr, ) -> String
Returns a Combined Log Format (CLF) line for one request/response pair:
IP - - [DD/Mon/YYYY:HH:MM:SS +0000] "METHOD URI VERSION" STATUS SIZE
pub fn server_url_thread_count( protocol: &str, bind_addr: &String, thread_count: i32, ) -> String
Auto Trait Implementations§
impl Freeze for Log
impl RefUnwindSafe for Log
impl Send for Log
impl Sync for Log
impl Unpin for Log
impl UnsafeUnpin for Log
impl UnwindSafe for Log
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