Repository navigation
[To dev/1.3] Fix schema alias validation and deletion performance (#18861) - #18871
Merged
Merged
Conversation
…pache#18861) * Fix schema mutation validation, accounting and deletion performance Validate aligned batch aliases, keep blacklist statistics idempotent, avoid repeated child scans during deletion, and correct and reuse device attribute storage. Add regression coverage for retries, snapshots, nested devices and all schema engine modes. * Fix aligned memchunk tests for current API (cherry picked from commit a498d7d)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Backport of #18861 (
a498d7d2a4608993c5c7d0c11f954e77b0554900) todev/1.3.Validate the shared measurement/alias namespace before aligned batch creation or merge in both Memory and PBTree schema engines. This rejects duplicate aliases and aliases that collide with another measurement before any schema mutation.
Maintain direct measurement and non-view child counts so in-memory timeseries deletion avoids rescanning all children for each measurement. Include the counters in memory accounting and preserve cleanup behavior for nested devices, snapshots and logical views.
Backport adaptations
Validation
mvn spotless:apply -pl iotdb-core/datanodemvn test -pl iotdb-core/datanode -am -Dtest=MTreeBelowSGMemoryImplTest,SchemaRegionAliasAndTagTest -Dsurefire.failIfNoSpecifiedTests=false -DfailIfNoTests=false— 45 tests passed, including all four Schema Engine test configurations.mvn test-compile -DskipTestsmvn test-compile -P with-zh-locale -DskipTestsThis PR has: