bobhan1 commented on code in PR #3329:
URL: https://github.com/apache/doris-website/pull/3329#discussion_r2757682095


##########
i18n/zh-CN/docusaurus-plugin-content-docs/current/table-design/storage-format.md:
##########
@@ -0,0 +1,68 @@
+---
+{
+    "title": "存储格式 V3",
+    "language": "zh-CN"
+}
+---
+
+<!-- 
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+Apache Doris 存储格式 V3 是在 Segment V2 
格式基础上进行的重大演进。它通过元数据解耦与编码策略优化,专门针对大宽表、复杂数据类型(如 Variant)以及云原生存算分离场景提升性能。
+
+## 核心优化点
+
+### 外部列元数据 (External Column Meta)
+*   **优化背景**:在 Segment V2 中,所有列的元数据(`ColumnMetaPB`)都存储在 Segment 文件的 Footer 
中。对于拥有数千列的大宽表或自动扩容的 Variant 场景,Footer 可能会膨胀到几 MB。
+*   **优化思路**:V3 将 `ColumnMetaPB` 从 Footer 中剥离,转而存储在文件内的独立区域(External Column 
Meta Area)。
+*   **收益**:
+    *   **极速元数据加载**:显著减小 Segment Footer 体积,加快文件初次打开速度。
+    *   **按需加载**:元数据可以按需从独立区域加载,降低内存占用,提升对象存储(如 S3/OSS)上的冷启动查询性能。
+
+### 数值类型 Plain 编码模式 (Integer Type Plain Encoding)
+*   **优化思路**:V3 默认将数值类型(如 `INT`, `BIGINT`)切换为 `PLAIN_ENCODING`(原始二进制存储),而非传统的 
BitShuffle。
+*   **收益**:配合 LZ4/ZSTD 压缩时,`PLAIN_ENCODING` 提供了更高的读取吞吐量和更低的 CPU 开销。在现代高速 IO 
环境下,这种“解压换性能”的策略在扫描大体量数据时优势明显。
+
+### 二进制 Plain 编码 V2 (Binary Plain Encoding V2)
+*   **优化思路**:引入 `BINARY_PLAIN_ENCODING_V2`,采用 `[长度(varuint)][原始数据]` 
的流式布局,取代了依赖末尾偏移表(Offsets)的旧格式。
+*   **收益**:消除了末尾庞大的偏移表,数据存储更加紧凑,且更利于指令流水线进行顺序扫描(Vectorized Sequential 
Scan),提升了字符串和 JSONB 类型的扫描效率。

Review Comment:
   > 且更利于指令流水线进行顺序扫描(Vectorized Sequential Scan),提升了字符串和 JSONB 类型的扫描效率。
   
   没有这个优势,`Binary Plain Encoding V2`这个改动的优化点只是减小存储空间
   读到内存后放到doris page cache之前还是会转成之前那种格式



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to