You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: Iceberg STRING table with an empty value is rejected as invalid manifest metadata #27210
A supported Iceberg STRING column containing an empty string is rejected during manifest parsing. Mapping DDL succeeds, but the first SELECT fails with:
ERROR 20400 (HY000): invalid state ICEBERG_METADATA_INVALID: Iceberg manifest entry is invalid [entry=0]
The error is stable in 3/3 independently created tables. No panic, restart, or connection loss was observed.
Expected Behavior
The table is valid Iceberg v2/Parquet data. MatrixOne must read all rows including the empty string, exactly as Spark does.
Steps to Reproduce
1. Create a table through Spark against the same Nessie REST catalog and MinIO warehouse:
CREATE TABLE tiera.string_boundary1.empty (id BIGINT, x STRING)
USING iceberg TBLPROPERTIES ('format-version'='2');
INSERT INTO tiera.string_boundary1.empty VALUES
(1, ''), (2, 'z'), (3, NULL);
2. Create the normal MatrixOne REST catalog/access mapping and map it:
CREATE EXTERNAL TABLE empty_t (id BIGINT, x TEXT) ENGINE=ICEBERG WITH (
'catalog'='type_min_cat', 'namespace'='string_boundary1', 'table'='empty',
'ref'='main', 'read_mode'='append_only', 'write_mode'='read_only'
);
3. Execute `SELECT COUNT(*), COUNT(x) FROM empty_t;`.
4. Repeat with independently created `string_boundary2.empty` and `string_boundary3.empty` tables.
Additional information
Controls:
Spark returns COUNT(*)=3, COUNT(x)=2.
The same table shape with nonempty ASCII strings (a, z, NULL) reads successfully 3/3.
The same table shape with Unicode nonempty strings (中文, é, NULL) reads successfully 3/3.
This is also consistent with a truncate-partitioned table that contains an empty string failing manifest parsing, while identity/bucket partitions with normal strings work.
Regression suggestion: Spark/Nessie/MinIO deterministic case with '', a nonempty ASCII string, a Unicode string and NULL; assert full scan and equality controls. No big-data data set is needed.
Activity
[-][Bug]:[/-][+][Bug]: Iceberg STRING table with an empty value is rejected as invalid manifest metadata[/+]fix(iceberg): accept empty string manifest bounds (#28153)
Ariznawlll commentedon Sep 8, 2026
最新 main(commit f72ca9e)本地验证:执行
mo-cgo-test ./test/iceberg -run TestLocalE2EEmptyStringReadCase -count=1 -p=1,空字符串/非空字符串/NULL 的结果断言及错误分支全部通过(0.445s)。当前 Docker 的 MinIO 已退出,缺少可读的 Spark/Nessie/MinIO Iceberg v2/Parquet 数据集,因此未执行真实 manifest 读取和COUNT(*)=3, COUNT(x)=2的外部表验收。结论:#28153 已在当前 main,代码级空字符串回归测试通过;真实 Iceberg manifest 读取待依赖服务恢复,暂不关闭。Ariznawlll commentedon Sep 16, 2026
测试版本
mainb347a62a30719cf3f2c8ca5a2da0dcfb11639f8c0.108.4、MinIO、Iceberg1.6.1、format v2 / Parquet。原问题验证
用 Spark 创建三个独立 Iceberg v2 / Parquet 表,并分别写入
(1, '')、一个非空字符串和(3, NULL);再以只读 Iceberg external table 映射读取。由于测试环境无法拉取 Spark 3.5.1 镜像,本次使用 Spark 3.5.4;Iceberg 版本保持为原问题的 1.6.1。该差异已记录,且本次验证的空字符串 manifest/read 路径一致。Happy Path 覆盖
COUNT(*)=3、COUNT(x)=2、COUNT(NULLIF(x,''))=1、x=''的行数为1;逐行可区分空字符串、非空字符串和 SQL NULL。(1, ''),(2, 'normal'),(3, NULL)与 Unicode 控制表(1, ''),(2, '中文'),(3, NULL)均返回3,2,1,1,并能读到各自的非空控制值。ICEBERG_METADATA_INVALID或 manifest entry invalid 错误。Unhappy Path 覆盖
COUNT(*)=3, COUNT(x)=2, empty_count=1,证明被拒绝操作没有改变源数据。白盒验证
不适用:原问题是外部 Iceberg manifest/read 的公开 SQL 行为,Spark/Nessie/MinIO 生成的真实 v2/Parquet fixture 已直接覆盖。未使用白盒注入替代该外部读取路径。
回归测试
已有针对空字符串读取的回归资产:
test/iceberg/iceberg_e2e_local.go和TestLocalE2EEmptyStringReadCase。本轮以真实 Spark 生成的 fixture 完成黑盒复验,未新增重复 case。测试证据
真实 Iceberg 读取的三张表统计分别为:空字符串表
3,2,1,1,ASCII 控制表3,2,1,1,Unicode 控制表3,2,1,1;每张表都核对了空字符串、非空字符串和 NULL 的逐行语义。固定 SHA 的回归代码链接见上节。测试结论
测试通过。
fix(iceberg): accept empty string manifest bounds (matrixorigin#28153)
fix(iceberg): accept empty string manifest bounds (matrixorigin#28153)
fix(iceberg): accept empty string manifest bounds (matrixorigin#28153)