checking connection inside loop

Why not put this logic directly to `percona-agent/mysql/mysql.go`. So directly to `Connect()` and `Close()`?