{"action":"created","issue":{"url":"https://api.github.com/repos/ros2/rclcpp/issues/660","repository_url":"https://api.github.com/repos/ros2/rclcpp","labels_url":"https://api.github.com/repos/ros2/rclcpp/issues/660/labels{/name}","comments_url":"https://api.github.com/repos/ros2/rclcpp/issues/660/comments","events_url":"https://api.github.com/repos/ros2/rclcpp/issues/660/events","html_url":"https://github.com/ros2/rclcpp/issues/660","id":422525395,"node_id":"MDU6SXNzdWU0MjI1MjUzOTU=","number":660,"title":"parameter client bug: wait_for_service sometimes failed","user":{"login":"huchhong","id":14917985,"node_id":"MDQ6VXNlcjE0OTE3OTg1","avatar_url":"https://avatars3.githubusercontent.com/u/14917985?v=4","gravatar_id":"","url":"https://api.github.com/users/huchhong","html_url":"https://github.com/huchhong","followers_url":"https://api.github.com/users/huchhong/followers","following_url":"https://api.github.com/users/huchhong/following{/other_user}","gists_url":"https://api.github.com/users/huchhong/gists{/gist_id}","starred_url":"https://api.github.com/users/huchhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/huchhong/subscriptions","organizations_url":"https://api.github.com/users/huchhong/orgs","repos_url":"https://api.github.com/users/huchhong/repos","events_url":"https://api.github.com/users/huchhong/events{/privacy}","received_events_url":"https://api.github.com/users/huchhong/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":16,"created_at":"2019-03-19T03:19:29Z","updated_at":"2019-04-01T05:11:55Z","closed_at":null,"author_association":"NONE","body":"\r\n## Bug report\r\n\r\n**Required Info:**\r\n\r\n- Operating System:\r\n  - ubuntu 16.04\r\n- Installation type:\r\n  -  from binary of crystal release \r\n- Version or commit hash:\r\n  - <!-- Output of git rev-parse HEAD, release version, or repos file  -->\r\n- DDS implementation:\r\n  - <!-- rmw_implementation used (e.g. Fast-RTPS, RTI Connext, etc -->\r\n- Client library (if applicable):\r\n  - <!-- e.g. rclcpp, rclpy, or N/A -->\r\n\r\n#### Steps to reproduce issue\r\nYesterday, i wrote a simple test to get myself familiar with parameter client in ros2.  My code is hosted at [example](https://github.com/huchhong/ros2_examples/tree/master/parameter). There is a luanch script which launchs a node to set parameter and another node to get parameter from first node using SyncParametersClient interaface. \r\n\r\nI ran this launch script multiple times, and found that sometimes the second node will wait too long for service after the first node has launched. This seems not good to me. \r\n\r\nIn a more rare case, after the first node has launched, the second node never successfully wait_for_service. The log is given below:\r\n```\r\n➜  ~ ros2 launch param_test access_other_node_param_launch.py\r\n[INFO] [launch]: process[set_and_get_parameters-1]: started with pid [38386]\r\n[INFO] [launch]: process[access_other_node_parameters-2]: started with pid [38387]\r\n[INFO] [access_other_node_parameters]: access parameters of other node\r\n[INFO] [set_and_get_parameters]:\r\nParameter name: foo\r\nParameter value (integer): 2\r\nParameter name: baz\r\nParameter value (double): 1.450000\r\nParameter name: bar\r\nParameter value (string): hello\r\nParameter name: foobar\r\nParameter value (bool): true\r\n[INFO] [access_other_node_parameters]: service not available, waiting again...\r\n[INFO] [access_other_node_parameters]: service not available, waiting again...\r\n[INFO] [access_other_node_parameters]: service not available, waiting again...\r\n```\r\n\r\nTo reproduce this error,  you can execute the launch file multiple times, maybe 10 or 20 times, and this should happen.\r\n\r\n#### Expected behavior\r\n\r\nQuick and successful response for wait_for_service in parameter client\r\n\r\n#### Actual behavior\r\n\r\nwaiting too long or more worse, never succuess\r\n"},"comment":{"url":"https://api.github.com/repos/ros2/rclcpp/issues/comments/478438011","html_url":"https://github.com/ros2/rclcpp/issues/660#issuecomment-478438011","issue_url":"https://api.github.com/repos/ros2/rclcpp/issues/660","id":478438011,"node_id":"MDEyOklzc3VlQ29tbWVudDQ3ODQzODAxMQ==","user":{"login":"richiware","id":6360749,"node_id":"MDQ6VXNlcjYzNjA3NDk=","avatar_url":"https://avatars0.githubusercontent.com/u/6360749?v=4","gravatar_id":"","url":"https://api.github.com/users/richiware","html_url":"https://github.com/richiware","followers_url":"https://api.github.com/users/richiware/followers","following_url":"https://api.github.com/users/richiware/following{/other_user}","gists_url":"https://api.github.com/users/richiware/gists{/gist_id}","starred_url":"https://api.github.com/users/richiware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/richiware/subscriptions","organizations_url":"https://api.github.com/users/richiware/orgs","repos_url":"https://api.github.com/users/richiware/repos","events_url":"https://api.github.com/users/richiware/events{/privacy}","received_events_url":"https://api.github.com/users/richiware/received_events","type":"User","site_admin":false},"created_at":"2019-04-01T05:11:55Z","updated_at":"2019-04-01T05:11:55Z","author_association":"NONE","body":"Sorry for the delay, I will try to check this week and find a solution."}}
{"actor":{"display_login":"richiware"}}