Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Log Address information in connection create/drop #154

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions src/pool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -559,11 +559,7 @@ impl ManageConnection for ServerPool {

/// Attempts to create a new connection.
async fn connect(&self) -> Result<Self::Connection, Self::Error> {
info!(
"Creating a new connection to {:?} using user {:?}",
self.address.name(),
self.user.username
);
info!("Creating a new server connection {:?}", self.address);

// Put a temporary process_id into the stats
// for server login.
Expand Down
3 changes: 2 additions & 1 deletion src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -607,7 +607,8 @@ impl Drop for Server {
let duration = now - self.connected_at;

info!(
"Server connection closed, session duration: {}",
"Server connection closed {:?}, session duration: {}",
self.address,
crate::format_duration(&duration)
);
}
Expand Down