Repository navigation
Prevent lost remote table attribute updates during broadcast - #19546
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #19546 +/- ##
============================================
+ Coverage 51.05% 51.07% +0.01%
Complexity 145 145
============================================
Files 5797 5797
Lines 430459 430461 +2
Branches 57371 57373 +2
============================================
+ Hits 219782 219858 +76
+ Misses 210677 210603 -74 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
JackieTien97
commented
Dec 6, 2026
A DataNode can lead several table SchemaRegions. Keep scanning after an empty region result so the remaining leaders can send their pending updates in the same round. Verify remote attribute reads across three databases on two DataNodes and cover migration version restoration for fetched regions.
|
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.



Problem
An exact-device query can keep returning an old table ATTRIBUTE after a SchemaRegion migration. In a two-DataNode cluster, warm the device attribute caches, move the single schema replica to the other DataNode, and run the following statements against the table used by
IoTDBTableTagSchemaMigrationIT.If the last write completes after the broadcaster serializes the preceding batch but before it samples the version, both batches carry version 3. The receiving DataNode discards the second batch and acknowledges the RPC. The sender clears the pending update. In a controlled reproduction, the former replica still returned
(z1, 14)and(z1, 15)after two broadcast intervals. The new leader returned(tagged-updated, 14)and(tagged-updated, 15).Changes
Verification
Both new regression tests failed against the previous implementation. With the fix, all 16 targeted DataNode unit tests and all five integration tests passed, including schema migration, delayed updates and degraded attribute backlogs. With the same serialization interleaving, the two batches carried versions 2 and 3 and both DataNodes returned the updated attribute on the first check. The full English and Chinese package builds also passed.