ZSTAC-85709 reject mixed management IP ranges#4167
Conversation
Only System L3 management networks reject mixed IPv4 and IPv6 ranges. Normal service L3 dual-stack behavior is unchanged. Resolves: ZSTAC-85709 Change-Id: I2076e6ab924848bbfc509bea1477c82017c18ecf
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: http://open.zstack.ai:20001/code-reviews/zstack-cloud.yaml (via .coderabbit.yaml) Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
总体概览该变更为 ZStack 网络层的管理网络添加了 IPv4/IPv6 地址段混用拦截机制:新增错误码常量、IP 范围版本校验逻辑、校验集成点和对应的集成测试,防止系统类别的管理网络混用不同 IP 协议版本的地址段。 变更详情管理网络 IPv4/IPv6 混用拦截
🎯 3 (Moderate) | ⏱️ ~20 分钟
Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (1 error, 1 warning)
✅ Passed checks (3 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ast-grep (0.42.3)utils/src/main/java/org/zstack/utils/clouderrorcode/CloudOperationsErrorCode.javaComment |
修复说明
管理网 System L3 不允许混用 IPv4/IPv6 IP range,避免 MN 发起 host/agent HTTP 调用时无法判断目标 IP family。
变更内容
验证
Jira: http://jira.zstack.io/browse/ZSTAC-85709
sync from gitlab !10072