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 'fast_forward' conns close due to 'log_unhealthy_connections' #4090

Merged
merged 1 commit into from
Feb 11, 2023
Merged
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
14 changes: 12 additions & 2 deletions lib/MySQL_Thread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3900,8 +3900,18 @@ void MySQL_Thread::process_all_sessions() {
if (sess->healthy==0) {
char _buf[1024];
if (sess->client_myds) {
if (mysql_thread___log_unhealthy_connections && sess->session_fast_forward == false) {
proxy_warning("Closing unhealthy client connection %s:%d\n",sess->client_myds->addr.addr,sess->client_myds->addr.port);
if (mysql_thread___log_unhealthy_connections) {
if (sess->session_fast_forward == false) {
proxy_warning(
"Closing unhealthy client connection %s:%d\n", sess->client_myds->addr.addr,
sess->client_myds->addr.port
);
} else {
proxy_warning(
"Closing 'fast_forward' client connection %s:%d\n", sess->client_myds->addr.addr,
sess->client_myds->addr.port
);
}
}
}
sprintf(_buf,"%s:%d:%s()", __FILE__, __LINE__, __func__);
Expand Down