IPv6-safe store address parsing (3 line change)#335
Conversation
|
Hi @BenCowen! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks! |
|
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks! |
|
Friendly ping @d4l3k @tushar00jain : 3-line, self-contained IPv6 parse fix, plus a unit test. |
|
@d4l3k has imported this pull request. If you are a Meta employee, you can view this in D112226662. (Because this pull request was imported automatically, there will not be any future comments.) |
|
@BenCowen can you rebase on main and fix the lint issues? trunk is green now I tried to fix it but I don't have permissions to your branch |
create_store_client split the rendezvous store address on the first colon and treated the remainder as the port, which mangles a bracket-less IPv6 address (e.g. on a flat-IPv6 fabric like Modal i6pn). Take the port as the field after the last colon instead; strip optional brackets from the host. Correct for IPv4 and for bare or bracketed IPv6.
ed923d6 to
5a38b80
Compare
|
Thanks @d4l3k, all set! |
|
This pull request has been merged in 90d7f68. |
Motivation
Add support for IPv6 fabric.
Summary
create_store_clientparses the rendezvous store address withpartition(":"), taking everything after the first colon as the port. That's the correct assumption forhost:port/ IPv4, but it doesn't apply to an IPv6 address, for example on a flat-IPv6 fabric where containers address each other directly by IPv6:Fix
Split off the
/prefixfirst, then take the port as the field after the last colon, and strip optional brackets from the host. Correct for IPv4, and for bare or bracketed IPv6 ([host]:port). One function, no signature change.Testing
Verified end-to-end on a flat-IPv6 fabric (Modal i6pn), single-process replica groups across separate containers:
allreduce(Gloo on CPU, and NCCL on GPU).HTTPTransport) and rejoins.Existing
host:port/ IPv4 behavior is unchanged.