MXS-1446: Add heartbeat conversion macros

The macros make the conversion from heartbeats to seconds more convenient
and consistent.
This commit is contained in:
Markus Mäkelä
2017-09-27 11:15:22 +03:00
parent 667440fbef
commit 0d6c06f33d
5 changed files with 16 additions and 7 deletions

View File

@ -82,8 +82,8 @@ void handle_connection_keepalive(RWSplit *inst, RWSplitSession *rses,
if (diff > keepalive)
{
MXS_INFO("Pinging %s, idle for %d seconds",
backend->name(), diff / 10);
MXS_INFO("Pinging %s, idle for %ld seconds",
backend->name(), HB_TO_SEC(diff));
modutil_ignorable_ping(backend->dcb());
}
}