Fix socket retry message (#3325)

This commit is contained in:
Philipp Moritz
2018-11-15 12:14:19 -08:00
committed by Robert Nishihara
parent 5319fd044c
commit b6a12d1f97
+4 -2
View File
@@ -67,8 +67,10 @@ int connect_ipc_sock_retry(const char *socket_pathname, int num_retries,
if (fd >= 0) {
break;
}
if (num_attempts == 0) {
RAY_LOG(ERROR) << "Connection to socket failed for pathname " << socket_pathname;
if (num_attempts > 0) {
RAY_LOG(ERROR) << "Retrying to connect to socket for pathname " << socket_pathname
<< " (num_attempts = " << num_attempts
<< ", num_retries = " << num_retries << ")";
}
/* Sleep for timeout milliseconds. */
usleep(timeout * 1000);