Skip to content

[HUDI-4144] Handle empty instants in Flink incremental input splits#5247

Closed
cuibo01 wants to merge 1 commit intoapache:masterfrom
cuibo01:loadAllData
Closed

[HUDI-4144] Handle empty instants in Flink incremental input splits#5247
cuibo01 wants to merge 1 commit intoapache:masterfrom
cuibo01:loadAllData

Conversation

@cuibo01
Copy link
Contributor

@cuibo01 cuibo01 commented Apr 7, 2022

What is the purpose of the pull request

If issuedInstant is empty, the endInstant should not skip the compaction timeline. This PR fixes that behaviour.

Brief change log

(for example:)

  • Modify AnnotationLocation checkstyle rule in checkstyle.xml

Verify this pull request

(Please pick either of the following options)

This pull request is a trivial rework / code cleanup without any test coverage.

(or)

This pull request is already covered by existing tests, such as (please describe tests).

(or)

This change added tests and can be verified as follows:

(example:)

  • Added integration tests for end-to-end.
  • Added HoodieClientWriteTest to verify the change.
  • Manually verified the change by running a job locally.

Committer checklist

  • Has a corresponding JIRA in PR title & commit

  • Commit message is descriptive of the change

  • CI is green

  • Necessary doc changes done or have another open PR

  • For large changes, please consider breaking it into sub-tasks under an umbrella JIRA.

@hudi-bot
Copy link
Collaborator

hudi-bot commented Apr 7, 2022

CI report:

Bot commands @hudi-bot supports the following commands:
  • @hudi-bot run azure re-run the last Azure build

@codope codope changed the title [MINOR]if issuedInstant is empty, the endInstant should not skip the … [HUDI-4144] Handle empty instants in Flink incremental input splits May 24, 2022
Copy link
Member

@codope codope left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.
@cuibo01 Can you please add a unit test to cover this scenario?

HoodieTableFileSystemView fsView = new HoodieTableFileSystemView(metaClient, commitTimeline, fileStatuses);
final String endInstant = instantToIssue.getTimestamp();
final String endInstant = instantRange == null ? fsView.getLastInstant().get().getTimestamp() : instantToIssue.getTimestamp();
final AtomicInteger cnt = new AtomicInteger(0);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm confused, when instantRange == null is true, that means the user first time query from earliest, and we should read to the latest commit instant, which should be instantToIssue here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point from Danny.
@cuibo01 Can you please explain that? Is it still a vlid scenario?

@yihua yihua added engine:flink Flink integration priority:high Significant impact; potential bugs labels Sep 13, 2022
@nsivabalan nsivabalan added the release-0.12.2 Patches targetted for 0.12.2 label Dec 6, 2022
@codope codope removed the release-0.12.2 Patches targetted for 0.12.2 label Dec 7, 2022
@github-actions github-actions bot added the size:S PR with lines of changes in (10, 100] label Feb 26, 2024
@yihua yihua added the area:table-service Table services label Mar 26, 2024
@yihua
Copy link
Contributor

yihua commented Mar 26, 2024

@danny0405 is this still an issue for Flink? I'm revisiting table service-related PRs for the 0.15.0 release.

@danny0405
Copy link
Contributor

Can be closed.

@danny0405 danny0405 closed this Mar 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:table-service Table services engine:flink Flink integration priority:high Significant impact; potential bugs size:S PR with lines of changes in (10, 100]

Projects

Status: 🏁 Triaged
Status: ✅ Done
Status: Done

Development

Successfully merging this pull request may close these issues.

6 participants