Rewrite stale_slaves

The behavior of mariadbmon was changed so that it better understands
slaves attempting to replicate. Rewrote the test to accommodate the change
in behavior and take the opportunity to use newer code.
This commit is contained in:
Markus Mäkelä
2018-08-11 14:18:48 +03:00
parent cef305e598
commit 804991404e
4 changed files with 121 additions and 81 deletions

View File

@ -295,6 +295,12 @@ public:
return get_row(m_conn, q);
}
std::string field(std::string q)
{
Row r = get_row(m_conn, q);
return r.empty() ? std::string() : r[0];
}
const char* error() const
{
return mysql_error(m_conn);