Skip to content

Fix snapshot pipe startup before IoTConsensus catch-up - #18534

Open
Caideyipi wants to merge 1 commit into
apache:masterfrom
Caideyipi:fix/snapshot-pipe-iotconsensus-catchup
Open

Fix snapshot pipe startup before IoTConsensus catch-up#18534
Caideyipi wants to merge 1 commit into
apache:masterfrom
Caideyipi:fix/snapshot-pipe-iotconsensus-catchup

Conversation

@Caideyipi

Copy link
Copy Markdown
Collaborator

Description

Snapshot/history-only Pipe sources use a heartbeat-only realtime source. With IoTConsensus, a Pipe task can start on a replica before writes from another writer have been asynchronously applied. The historical scan then sees no TsFiles, emits its terminate event, and allows the Pipe to be auto-dropped before the delayed writes arrive.

This change waits for all remote IoTConsensus writers to finish synchronizing their logs before a heartbeat-only DataRegion source begins historical extraction. The wait runs outside the DataRegion write lock so remote writes can still be applied. Other consensus protocols and realtime Pipe source modes retain the existing startup path.

Verification

  • mvn spotless:apply -pl iotdb-core/consensus,iotdb-core/datanode
  • Consensus module compilation passed
  • DataNode full-module compilation is blocked locally by unrelated stale dependency/generated-source errors

@Caideyipi Caideyipi closed this Aug 27, 2026
@Caideyipi Caideyipi reopened this Aug 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant