feat(ipv6): support IPv6 and dual-stack pods for engine and replica#492
Conversation
|
Hello @COLDTURNIP |
0753a96 to
62773f3
Compare
f267ece to
c11f4a9
Compare
There was a problem hiding this comment.
Pull request overview
This PR aims to enable IPv6 and dual-stack pod support in the SPDK engine/replica path by removing IPv4-only assumptions and selecting NVMe/TCP address family dynamically.
Changes:
- Use a detected NVMe-oF address family (IPv4 vs IPv6) when attaching NVMe controllers and setting listener ANA state.
- Relax replica-side exposed-port detection and engine-side NVMe transport validation to no longer require IPv4.
- Add unit tests for exposed port selection and address-family detection.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| pkg/spdk/util.go | Uses detected address family for BdevNvmeAttachController instead of hardcoding IPv4. |
| pkg/spdk/engine.go | Uses detected address family for ANA-state RPC + replica attach during restore; relaxes IPv4-only transport validation. |
| pkg/spdk/replica.go | Stops filtering exposed ports by IPv4-only listeners (accepts IPv6). |
| pkg/spdk/util_test.go | Adds test validating address-family detection behavior. |
| pkg/spdk/engine_test.go | Adds tests for getExposedPort behavior across IPv4/IPv6 and non-TCP listeners. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
0c69ac3 to
9b2bb45
Compare
|
@COLDTURNIP CI failed, |
It seems to be the upstream package resolving issue. Zypper package |
Blocked by: longhorn/longhorn#12971 |
Signed-off-by: Raphanus Lo <yunchang.lo@suse.com>
longhorn-10928 Signed-off-by: Raphanus Lo <yunchang.lo@suse.com>
9b2bb45 to
d665066
Compare
Replace hardcoded IPv4 address family with dynamic detection using net.ParseIP across engine, replica, and util modules.
Which issue(s) this PR fixes:
Issue longhorn/longhorn#10928
What this PR does / why we need it:
To make v2 data engine supports IPv6. This change dependent to longhorn/go-spdk-helper#276
Special notes for your reviewer:
Additional documentation or context