Open
[RFC] KASandbox 接入元戎 DataSystem 作为模板与快照存储后端 #15
cheyulinAdd on 19 days ago
19 days ago Assign yche-huawei as responsible person
19 days ago Added label: sig/sig-CloudNative
openeuler-ci-bot
19 days ago Comments:
19 days ago Comments:
Welcome To openEuler Community
Hey @yche-huawei , thanks for your contribution to the community.
Bot Usage Manual
I'm the Bot here serving you. You can find the instructions on how to interact with me at Here . That means you can comment below every pull request or issue to trigger Bot Commands. You can self-configure the PR merge rules for this repository. For more details, please refer to Here.
Contact Guide
If you have any questions, please contact the SIG: sig-CloudNative ,
and any of the maintainers: @duguhaotian, @feijianqiang, @gaodaweiky, @jimmieme, @lu-wei-army, @weibaohui, @wonleing, @yangzhao_kl, @zhaoyifan28, @zmr_2020 ,
and any of the committers: @feijianqiang, @zhourenjianz .


19 days ago Associated pull request
19 days ago Modify description of issue
19 days ago changed custom state from 新建 to 开发中
19 days ago Modify description of issue
KASandbox 接入元戎 DataSystem 作为模板与快照存储后端
状态 征求意见
实现候选 KASandbox PR #258,提交
e0b9ed1c92d513b94176822bf7a1d0be184ddb19。PR #258功能验收基线
2c924c562446a9613d66a1476110966daff37688。当前提交的代码树与验收基线一致。01 目的与范围
为模板、快照和构建缓存增加一个可显式启用的元戎 DataSystem 后端。模板构建需要连续上传大对象,沙箱恢复需要按偏移随机读,迁移需要完整写入、验读和可重复执行。三条路径共用一个字节对象格式,使迁移产物可由运行时直接消费,并让 KAS 继续通过既有
StorageProvider选择后端。第一阶段交付
YuanRongBucket、yr://迁移目标、原生 SDK 构建接入和对象目录。评审重点是对象发布与清理语义、两层镜像映射的边界,以及启用和回滚所需的运维条件。02 File 与 KV 的两层映射
packages/storage-yrSet/Get/Exist/QuerySize/Del,File 层的Size/Exists基于已发布目录和 manifest物理 Key 由 namespace 摘要、路径摘要、随机 generation 和片偏移组成。manifest 使用
_m,分片使用_c_<offset>。目前使用的公共 KV 接口按 Key 操作,逻辑前缀枚举和发布指针由目录提供。运行时和迁移复用这套编码。File 与 KV 代码分析03 读写、并发和异常边界
目录事务和 WAL 保障目录状态。KV payload 的保有由 DataSystem 写入策略和部署决定,快照 ready 与祖先可达性由 KAS 管理。
04 启用、迁移和回滚
YuanRongBucket,初始化 PostgreSQL 目录,配置 Worker 地址、namespace 和所需的写入保有策略。编译头文件、链接库和运行时加载库使用匹配的 SDK 与 ABI。migrate-tool以yr://作为目标,使用相同编码。按完整 SHA-256 判定复用或冲突,写入结束关闭写端后另开读端验读。05 验证与验收边界
冷恢复验证了原 KAS 写进程退出后,由新 KAS 读进程在空物理缓存中恢复,DataSystem、etcd 和 PostgreSQL 在切换期间保活。Worker 重启持久性、跨机故障切换、生产 HA、完整 VM 迁移与生产容量指标需要独立验收。功能验证与原始证据
06 性能演进与评审问题
当前 PR 使用 v1 manifest、整片 SHA-256、SDK 字符串读取和逐片登记。后续实验补丁独立评审 Buffer Get、BLAKE3 v2、校验与上传重叠,以及事务批量登记。v2 需要读端先升级,再启用写端。性能验收分别比较 File 读写、冷块回填和沙箱恢复,记录有效 Worker 容量、请求放大和同请求 SDK/File 耗时。跨机性能单独验收。后续同机实验与补丁
本文由 Codex(GPT-6)根据 PR #258 源码及其公开验证材料辅助整理。核心任务是说明接入目的、设计取舍和验收边界。本文为讨论草案,供人工评审。