branch-4.1: [feat](Variant) Support NestedGroup public config#64679
branch-4.1: [feat](Variant) Support NestedGroup public config#64679eldenmoon wants to merge 1 commit into
Conversation
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
There was a problem hiding this comment.
Pull request overview
Note
Copilot couldn't run its full agentic review because no GitHub Actions runner was available. Make sure your repository has a runner available to run Copilot's review, or add a copilot-setup-steps.yml file specifying one with the runs-on attribute. See the docs for more details.
Enables VARIANT NestedGroup support as a public configuration and wires build-time toggles for the NestedGroup feature module.
Changes:
- Adjusts FE parsing/serialization and tests to accept
variant_enable_nested_groupand validate conflicts with doc mode. - Adds BE build flags and CMake integration to optionally compile a NestedGroup module and its unit tests.
- Updates default NestedGroup-related config and strengthens default provider behavior to reject write path when not built.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| regression-test/suites/variant_p0/test_variant_search_subcolumn.groovy | Adds context comment tying the suite to Variant SEARCH subcolumn binding behavior. |
| fe/fe-core/src/test/java/org/apache/doris/nereids/parser/NereidsParserTest.java | Updates parser tests to accept NestedGroup property and assert conflict error with doc mode. |
| fe/fe-core/src/test/java/org/apache/doris/catalog/TypeTest.java | Updates VariantType SQL serialization test to require nested group property output. |
| fe/fe-core/src/main/java/org/apache/doris/nereids/parser/LogicalPlanBuilder.java | Changes NestedGroup parsing behavior from “reject” to “override/disable other features”. |
| fe/fe-common/src/main/java/org/apache/doris/catalog/VariantType.java | Serializes variant_enable_nested_group into toSql(). |
| build.sh | Adds env-driven cmake options for enabling NestedGroup module and setting its directory. |
| be/test/storage/segment/nested_group_provider_test.cpp | Expands tests ensuring default provider rejects NestedGroup write path with correct status codes. |
| be/test/CMakeLists.txt | Conditionally includes NestedGroup module unit tests when feature is enabled. |
| be/src/storage/segment/variant/nested_group_provider.cpp | Changes default write provider from no-op OK to NotSupported. |
| be/src/storage/CMakeLists.txt | Conditionally replaces default provider with module sources when NestedGroup feature is enabled. |
| be/src/common/config.cpp | Changes default for variant_nested_group_discard_scalar_on_conflict to true. |
| be/CMakeLists.txt | Adds ENABLE_NESTED_GROUP option and requires module dir when enabled. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| enableVariantDocMode = false; | ||
| variantMaxSubcolumnsCount = 0; | ||
| enableTypedPathsToSparse = false; | ||
| variantMaxSparseColumnStatisticsSize = 0; | ||
| variantSparseHashShardCount = 0; |
| if (enableNestedGroup) { | ||
| sb.append(","); | ||
| sb.append("\"variant_enable_nested_group\" = \"") | ||
| .append(String.valueOf(enableNestedGroup)).append("\""); | ||
| } |
| if (ENABLE_NESTED_GROUP) | ||
| file(GLOB_RECURSE NESTED_GROUP_UT_FILES CONFIGURE_DEPENDS | ||
| "${CMAKE_CURRENT_SOURCE_DIR}/${NESTED_GROUP_MODULE_DIR}/*.cpp") | ||
| list(APPEND UT_FILES ${NESTED_GROUP_UT_FILES}) | ||
| endif() |
| // Deeper arrays will be stored as JSONB | ||
| DEFINE_mInt32(variant_nested_group_max_depth, "10"); | ||
| DEFINE_mBool(variant_nested_group_discard_scalar_on_conflict, "false"); | ||
| DEFINE_mBool(variant_nested_group_discard_scalar_on_conflict, "true"); |
| -DENABLE_NESTED_GROUP="${ENABLE_NESTED_GROUP}" \ | ||
| -DNESTED_GROUP_MODULE_DIR="${WITH_NESTED_GROUP_DIR}" \ |
72698ac to
307593f
Compare
|
run buildall |
FE UT Coverage ReportIncrement line coverage |
FE Regression Coverage ReportIncrement line coverage |
|
run buildall |
307593f to
a4dddd3
Compare
FE UT Coverage ReportIncrement line coverage |
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
FE Regression Coverage ReportIncrement line coverage |
cherry-pick #9818