Skip to content

[Pipe] Avoid no-op ConfigNode consensus writes for covered progress - #18574

Merged
jt2594838 merged 1 commit into
apache:masterfrom
Caideyipi:fix/skip-noop-pipe-progress-ratis-write
Sep 21, 2026
Merged

jt2594838 merged 1 commit into
apache:masterfrom
Caideyipi:fix/skip-noop-pipe-progress-ratis-write

Conversation

@Caideyipi

Copy link
Copy Markdown
Collaborator

Description

Motivation

A DataNode pipe heartbeat can report a composite progress index that is already fully covered by the ConfigNode progress. The previous isAfter() || equals() guard does not represent greater-than-or-equal semantics for partially ordered indexes such as RecoverProgressIndex. It can therefore merge to the same logical value, set the ConfigNode consensus-write flag, and periodically submit a no-op PipeHandleMetaChangeProcedure, producing unnecessary Ratis log entries.

Changes

  • Use ProgressIndex.isEqualOrAfter() to skip updates when ConfigNode already covers the DataNode progress.
  • Keep consensus writes when the DataNode heartbeat genuinely advances progress.
  • Log the coordinator progress captured before an actual update.
  • Add regression tests for both covered and advancing composite progress indexes.

Validation

  • mvn spotless:apply -pl iotdb-core/confignode
  • mvn -pl iotdb-core/confignode -Dtest=PipeHeartbeatParserTest -DfailIfNoTests=false test

This PR has:

  • been self-reviewed.
  • added unit tests to cover the new code paths.
Key changed classes
  • PipeHeartbeatParser
  • PipeHeartbeatParserTest

@jt2594838
jt2594838 merged commit 5aae669 into apache:master Sep 21, 2026
39 checks passed
@jt2594838
jt2594838 deleted the fix/skip-noop-pipe-progress-ratis-write branch September 21, 2026 02:45
jt2594838 pushed a commit that referenced this pull request Sep 22, 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.

2 participants