libtest::Server(host_arg, port_arg,
MEMCACHED_BINARY, is_memcached_libtool(), is_socket_arg)
{
- set_pid_file();
}
virtual const char *sasl() const
return _username;
}
- bool wait_for_pidfile() const
+ virtual bool has_pid_file() const
{
- Wait wait(pid(), 4);
-
- return wait.successful();
+ return false;
}
bool ping()
{
-#if 0
- // Memcached is slow to start, so we need to do this
- if (pid_file().empty() == false)
- {
- if (wait_for_pidfile() == false)
- {
- Error << "Pidfile was not found:" << pid_file() << " :" << running();
- return -1;
- }
- }
-#endif
-
memcached_return_t rc;
bool ret;
if (memcached_failed(rc) or ret == false)
{
- Error << "libmemcached_util_ping(" << hostname() << ", " << port() << ") error: " << memcached_strerror(NULL, rc);
+ error(memcached_strerror(NULL, rc));
}
return ret;
bool ping()
{
- // Memcached is slow to start, so we need to do this
- if (pid_file().empty() == false)
- {
- if (wait_for_pidfile() == false)
- {
- Error << "Pidfile was not found:" << pid_file();
- return -1;
- }
- }
-
memcached_return_t rc;
bool ret;
if (memcached_failed(rc) or ret == false)
{
- Error << "libmemcached_util_ping2(" << hostname() << ", " << port() << ", " << username() << ", " << password() << ") error: " << memcached_strerror(NULL, rc);
+ error(memcached_strerror(NULL, rc));
}
return ret;