-
-
Notifications
You must be signed in to change notification settings - Fork 763
Exclude comm handshake from connect timeout #7698
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
e2295c0
1dccdb0
c6af0ae
865bfb2
a445ec3
d7214e2
143977e
716fc65
d23d988
08353e1
d069db4
4fd630d
4db4070
3e6f0f6
a1723de
bd2ba8f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -5864,22 +5864,6 @@ async def test_client_timeout_2(): | |
| assert stop - start < 1 | ||
|
|
||
|
|
||
| @gen_test() | ||
| async def test_client_active_bad_port(): | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. http servers wait for a |
||
| import tornado.httpserver | ||
| import tornado.web | ||
|
|
||
| application = tornado.web.Application([(r"/", tornado.web.RequestHandler)]) | ||
| http_server = tornado.httpserver.HTTPServer(application) | ||
| http_server.listen(8080) | ||
| with dask.config.set({"distributed.comm.timeouts.connect": "10ms"}): | ||
| c = Client("127.0.0.1:8080", asynchronous=True) | ||
| with pytest.raises((TimeoutError, IOError)): | ||
| async with c: | ||
| pass | ||
| http_server.stop() | ||
|
|
||
|
|
||
| @pytest.mark.parametrize("direct", [True, False]) | ||
| @gen_cluster(client=True, client_kwargs={"serializers": ["dask", "msgpack"]}) | ||
| async def test_turn_off_pickle(c, s, a, b, direct): | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1538,6 +1538,8 @@ async def close( # type: ignore | |
| for pc in self.periodic_callbacks.values(): | ||
| pc.stop() | ||
|
|
||
| self.stop() | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Moving this up here has broken P2P restarts by introducing a new race condition (or making it exponentially more likely to occur). Why do we need this change? See #8011 (comment) for more on the P2P problem.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I vaguely remember having a conversation with @graingert about this but can't recall the details. I believe there were a couple of connections left hanging because they were initiated during worker close and were never properly aborted. Not allowing any more connections once we are closing felt like a sane thing to do.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't have any issues with reverting this change but I am a bit reluctant to revert the handshake timeout removal. I assume that this is required to keep many tests green. |
||
|
|
||
| # Cancel async instructions | ||
| await BaseWorker.close(self, timeout=timeout) | ||
|
|
||
|
|
@@ -1640,7 +1642,6 @@ def _close(executor, wait): | |
| executor=executor, wait=executor_wait | ||
| ) # Just run it directly | ||
|
|
||
| self.stop() | ||
| await self.rpc.close() | ||
|
|
||
| self.status = Status.closed | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.