Unix socket support - #9337
Conversation
|
@jacobtomlinson could you let me know if you would be interested in merging this PR (after feedback/refactoring of course)? Thanks! |
jacobtomlinson
left a comment
There was a problem hiding this comment.
This generally seems like a positive change. I agree that I like unix:// more. I would be apprehensive to make this the default without broader community testing, but I agree that it's a better default in the long run.
Could I ask you to make sure CI is happy (unrelated failures are fine) and add docs?
Unit Test ResultsSee test report for an extended history of previous test failures. This is useful for diagnosing flaky tests. 20 files - 20 20 suites - 20 7h 22m 5s ⏱️ - 7h 13m 11s For more details on these failures, see this check. Results for commit 34d977e. ± Comparison against base commit 40fcd99. This pull request removes 42 and adds 4 tests. Note that renamed tests count towards both.This pull request skips 4 tests.♻️ This comment has been updated with latest results. |
Make get_uds_path() respect XDG_RUNTIME_DIR and dask.config['temporary-directory']
Resolves #3630
This PR adds support for Unix Domain Sockets...
commsThe rationale for this is twofold:
Test this branch with:
New UDS backend
This is the main part of this PR. We implement a new backend
UDSwhich subclasses the standardTCPclasses. When setting protocol on a cluster/worker/scheduler touds://, this backend is used. When a worker or scheduler is given an absolute path, it will use that absolute path to create the unix socket. If instead any other value is passed in (e.g. the defaultlocalhost), the backend will create the socket at a new temporary path.Benefits
Performance
@mrocklin tested this:
Security
UDS support is desireable for usecases where:
inproc)ucxis not available (e.g. not on Linux)tcp).dask-labextensionfor instance), or desired (more overhead).Dashboard listening on UDS
When the
dashboard_urlis set to an absolute path, listen on UDS instead of TCP. This can help prevent new CVE's of the form GHSA-c336-7962-wfj2Todo
pixi run linttest_comms.py?unix://instead ofuds://?