Reduce the internal timeouts (#613)

Debugging #611 these timeouts were so long that the overall test timeout was being triggered before these internal timeouts were triggered.

1000 retries at 100ms -> 10 seconds each. I cut it down to 1 second for each to establish the connection.

Signed-off-by: Tully Foote <tfoote@osrfoundation.org>
This commit is contained in:
Tully Foote 2020-05-13 14:27:22 -07:00 committed by GitHub
parent c64ca630f7
commit 6d16465318
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View file

@ -179,7 +179,7 @@ int main(int argc, char ** argv)
}); });
// Wait until server is available // Wait until server is available
if (!wait_for_server_to_be_available(&node, &client, 1000, 100)) { if (!wait_for_server_to_be_available(&node, &client, 10, 100)) {
RCUTILS_LOG_ERROR_NAMED(ROS_PACKAGE_NAME, "Server never became available"); RCUTILS_LOG_ERROR_NAMED(ROS_PACKAGE_NAME, "Server never became available");
return -1; return -1;
} }
@ -214,7 +214,7 @@ int main(int argc, char ** argv)
memset(&client_response, 0, sizeof(test_msgs__srv__BasicTypes_Response)); memset(&client_response, 0, sizeof(test_msgs__srv__BasicTypes_Response));
test_msgs__srv__BasicTypes_Response__init(&client_response); test_msgs__srv__BasicTypes_Response__init(&client_response);
if (!wait_for_client_to_be_ready(&client, &context, 1000, 100)) { if (!wait_for_client_to_be_ready(&client, &context, 10, 100)) {
RCUTILS_LOG_ERROR_NAMED(ROS_PACKAGE_NAME, "Client never became ready"); RCUTILS_LOG_ERROR_NAMED(ROS_PACKAGE_NAME, "Client never became ready");
return -1; return -1;
} }

View file

@ -164,7 +164,7 @@ int main(int argc, char ** argv)
// Block until a client request comes in. // Block until a client request comes in.
if (!wait_for_service_to_be_ready(&service, &context, 1000, 100)) { if (!wait_for_service_to_be_ready(&service, &context, 10, 100)) {
RCUTILS_LOG_ERROR_NAMED(ROS_PACKAGE_NAME, "Service never became ready"); RCUTILS_LOG_ERROR_NAMED(ROS_PACKAGE_NAME, "Service never became ready");
return -1; return -1;
} }