Skip to content

[HUDI-5479] Avoid to read the archived timeline each time for meta sync#7564

Closed
danny0405 wants to merge 1 commit intoapache:masterfrom
danny0405:HUDI-5479
Closed

[HUDI-5479] Avoid to read the archived timeline each time for meta sync#7564
danny0405 wants to merge 1 commit intoapache:masterfrom
danny0405:HUDI-5479

Conversation

@danny0405
Copy link
Contributor

The user reports OOM error usually because of the archived timeline deserialization, which occurs for every meta sync after an instant is committed.

Change Logs

Avoid to dese the archived timeline each instant commit.

Impact

None

Risk level (write none, low medium or high below)

none

Documentation Update

Describe any necessary documentation update if there is any new feature, config, or user-facing change

  • The config description must be updated if new configs are added or the default value of the configs are changed
  • Any new feature or user-facing change requires updating the Hudi website. Please create a Jira ticket, attach the
    ticket number here and follow the instruction to make
    changes to the website.

Contributor's checklist

  • Read through contributor's guide
  • Change Logs and Impact were stated clearly
  • Adequate tests were added if applicable
  • CI passed

neverdizzy added a commit to neverdizzy/hudi that referenced this pull request Dec 27, 2022
https://github.com/apache/hudi/pull/7564/files
[HUDI-5479] Avoid to read the archived timeline each time for meta sync apache#7564
final HoodieDefaultTimeline timeline = metaClient.getActiveTimeline().isBeforeTimelineStarts(lastCommitTimeSynced.get())
? metaClient.getArchivedTimeline(lastCommitTimeSynced.get()).mergeTimeline(metaClient.getActiveTimeline())
: metaClient.getActiveTimeline();
return TimelineUtils.getWrittenPartitions(timeline.getCommitsTimeline().findInstantsAfter(lastCommitTimeSynced.get(), Integer.MAX_VALUE));
Copy link
Member

Choose a reason for hiding this comment

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

similar logic can be applied to getDroppedPartitionsSince()

@xushiyan
Copy link
Member

also pls rebase to get the CI to pass

The user reports OOM error usually because of the archived timeline deserialization,
which occurs for every meta sync after an instant is committed.
@hudi-bot
Copy link
Collaborator

CI report:

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

@danny0405
Copy link
Contributor Author

Close because there is another fix in: https://github.com/apache/hudi/pull/7561/files

@danny0405 danny0405 closed this Dec 28, 2022
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.

3 participants