Skip to content

[flink] Extract shared checkpoint/savepoint utilities to base class#2761

Open
MehulBatra wants to merge 3 commits intoapache:mainfrom
MehulBatra:base-class-checkpointing-methods
Open

[flink] Extract shared checkpoint/savepoint utilities to base class#2761
MehulBatra wants to merge 3 commits intoapache:mainfrom
MehulBatra:base-class-checkpointing-methods

Conversation

@MehulBatra
Copy link
Contributor

Purpose

Linked issue: close #2758

Brief change log

New File:

  • Created FlussVirtualTableITCaseBase.java
    • Shared @tempdir fields: checkpointDir, savepointDir
    • Shared utility methods: getFileBasedCheckpointsConfig(), waitForCheckpoint()

Modified:

  • BinlogVirtualTableITCase.java
    • Now extends FlussVirtualTableITCaseBase
  • ChangelogVirtualTableITCase.java
    • Now extends FlussVirtualTableITCaseBase

Tests

  • All existing tests remain unchanged

API and Format

Documentation

@MehulBatra MehulBatra requested a review from wuchong March 1, 2026 14:18
@MehulBatra
Copy link
Contributor Author

@wuchong @nhuantho Could you please help review!

@nhuantho
Copy link
Contributor

nhuantho commented Mar 1, 2026

Hi @MehulBatra, I was wondering why the initTableEnvironment method wasn’t moved to FlussVirtualTableITCaseBase.

@MehulBatra
Copy link
Contributor Author

Hi @MehulBatra, I was wondering why the initTableEnvironment method wasn’t moved to FlussVirtualTableITCaseBase.

The method has test-specific dependencies that would couple the tests unnecessarily.

@nhuantho
Copy link
Contributor

nhuantho commented Mar 2, 2026

Hi, @MehulBatra, the idea of #2477 from FlinkTableSourceFailOverITCase. So, these methods are not only used in BinlogVirtualTableITCase and ChangelogVirtualTableITCase. Whether, can we create a util class like FinkCheckpointsUtils in src/test/java/org/apache/fluss/flink/source/testutils?

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.

[flink] Rewrite waitForCheckpoint, getFileBasedCheckpointsConfig to a shared base class

2 participants