hongzhi-gao opened a new pull request, #18803:
URL: https://github.com/apache/iotdb/pull/18803
## Description
### Problem
During DataRegion recovery after a restart, an empty asynchronous recovery
task list could still enter the subsequent registration flow. This could
register
the same DataRegion twice for scheduling, causing each TTL check to run
twice and producing adjacent duplicate log entries.
### Changes
- Continue with asynchronous recovery and its registration flow only when
the task list is non-empty.
- Prevent duplicate DataRegion entries during registration.
- Remove all entries for a DataRegion during unregistration, including
duplicates left by earlier registrations.
### Testing
A temporary integration test started an IoTConsensusV2 node, wrote and
flushed data, then restarted the node with its data preserved and checked the
TTL
logs. The temporary test was not added to this PR.
<hr>
This PR has:
- [x] been tested in a test IoTDB cluster.
<hr>
##### Key changed classes in this PR
- StorageEngine: skips the asynchronous recovery flow when there are no
tasks.
- CompactionScheduleTaskManager: deduplicates registration and removes
duplicate entries on unregistration.
--
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]