]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
test/{librbd, rgw}: retry when bind fail with port 0 47962/head 47963/head
authorKefu Chai <tchaikov@gmail.com>
Sun, 4 Sep 2022 12:37:32 +0000 (20:37 +0800)
committerKefu Chai <tchaikov@gmail.com>
Mon, 5 Sep 2022 13:04:34 +0000 (21:04 +0800)
commitaa7885f7cc41390fcc8eeb82bc7142c3ff6a53f9
tree8ceab7646b7aac3744bc45d8c0de3da5ad07440c
parenta873546c0df5635a149391b2b315c20a6bb4ba8e
test/{librbd, rgw}: retry when bind fail with port 0

there is chance that the bind() call may fail if we have another test
happen to pick the free port picked by operating system. in this case,
we just retry up to 42 times.

in theory, this change does not fully address the racing, but it should
help to alleviate this issue.

See-also: https://tracker.ceph.com/issues/57116
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
src/test/librbd/migration/test_mock_HttpClient.cc
src/test/rgw/test_http_manager.cc