Skip to content

Conversation

@zhangyue19921010
Copy link
Contributor

@zhangyue19921010 zhangyue19921010 commented Jul 20, 2021

What is the purpose of the pull request

Since #2422 Cleaner now takes care of removing replaced file groups. This call to deleteReplacedFileGroups can be removed.

Also it's a little confused that archive can delete data file even users set auto.clean false.

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 Jul 20, 2021

CI report:

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

@codecov-commenter
Copy link

codecov-commenter commented Jul 20, 2021

Codecov Report

Merging #3310 (f0b369b) into master (572a214) will decrease coverage by 0.04%.
The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #3310      +/-   ##
============================================
- Coverage     47.83%   47.78%   -0.05%     
- Complexity     5565     5598      +33     
============================================
  Files           936      938       +2     
  Lines         41663    41815     +152     
  Branches       4197     4211      +14     
============================================
+ Hits          19929    19983      +54     
- Misses        19960    20045      +85     
- Partials       1774     1787      +13     
Flag Coverage Δ
hudicli 39.97% <ø> (ø)
hudiclient 34.59% <ø> (+0.06%) ⬆️
hudicommon 48.63% <ø> (-0.04%) ⬇️
hudiflink 59.65% <ø> (+0.29%) ⬆️
hudihadoopmr 52.02% <ø> (ø)
hudisparkdatasource 67.18% <ø> (-0.10%) ⬇️
hudisync 55.97% <ø> (ø)
huditimelineservice 64.07% <ø> (ø)
hudiutilities 59.87% <ø> (+0.10%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...rg/apache/hudi/table/HoodieTimelineArchiveLog.java 0.00% <ø> (ø)
...va/org/apache/hudi/keygen/BuiltinKeyGenerator.java 62.12% <0.00%> (-10.86%) ⬇️
...g/apache/hudi/keygen/GlobalDeleteKeyGenerator.java 90.90% <0.00%> (-9.10%) ⬇️
...apache/hudi/keygen/NonpartitionedKeyGenerator.java 90.90% <0.00%> (-9.10%) ⬇️
...pache/hudi/common/table/HoodieTableMetaClient.java 61.90% <0.00%> (-2.85%) ⬇️
...java/org/apache/hudi/config/HoodieWriteConfig.java 43.37% <0.00%> (-0.15%) ⬇️
.../java/org/apache/hudi/common/util/CommitUtils.java 40.47% <0.00%> (ø)
...he/hudi/sink/partitioner/BucketAssignFunction.java 80.00% <0.00%> (ø)
...ava/org/apache/hudi/keygen/SimpleKeyGenerator.java 100.00% <0.00%> (ø)
...n/java/org/apache/hudi/internal/DefaultSource.java 0.00% <0.00%> (ø)
... and 42 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 572a214...f0b369b. Read the comment docs.

@vinothchandar
Copy link
Member

@satishkotha do you mind taking a second look at this? Seems ok to do.

Copy link
Member

@satishkotha satishkotha left a comment

Choose a reason for hiding this comment

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

LGTM. Couple minor comments to see if we can remove more dead code.


TableFileSystemView fileSystemView = this.table.getFileSystemView();
List<String> replacedPartitions = getReplacedPartitions(instant);
return ReplaceArchivalHelper.deleteReplacedFileGroups(context, metaClient, fileSystemView, instant, replacedPartitions);
Copy link
Member

Choose a reason for hiding this comment

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

Do we need ReplaceArchivalHelper class?


// when using insert_overwrite or insert_overwrite_table
// first commit may without replaceFileIds
createReplaceMetadataWithoutReplaceFileId("000");
Copy link
Member

Choose a reason for hiding this comment

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

Could we also remove these helper methods?

@satishkotha
Copy link
Member

@hudi-bot run azure

LGTM. i'll merge after azure builds pass

@satishkotha satishkotha merged commit 9e83085 into apache:master Aug 11, 2021
@zhangyue19921010
Copy link
Contributor Author

Hi @satishkotha Thanks a lot for your review and merge!

liujinhui1994 pushed a commit to liujinhui1994/hudi that referenced this pull request Aug 12, 2021
…pache#3310)

* remove delete replaced file when archive

* done

* remove unsed import

* remove delete replaced files when archive realted UT

* code reviewed

Co-authored-by: yuezhang <[email protected]>
leesf pushed a commit to leesf/hudi that referenced this pull request Nov 24, 2022
…pache#3310)

* remove delete replaced file when archive

* done

* remove unsed import

* remove delete replaced files when archive realted UT

* code reviewed

Co-authored-by: yuezhang <[email protected]>
leesf pushed a commit to leesf/hudi that referenced this pull request Nov 24, 2022
…rchive (apache#3310)"

This reverts commit 2c2cab1e32e42cd59b5edee9b37dfd1c5946a9de.
leesf pushed a commit to leesf/hudi that referenced this pull request Nov 24, 2022
…pache#3310)

* remove delete replaced file when archive

* done

* remove unsed import

* remove delete replaced files when archive realted UT

* code reviewed

Co-authored-by: yuezhang <[email protected]>
leesf pushed a commit to leesf/hudi that referenced this pull request Nov 24, 2022
…rchive (apache#3310)"

This reverts commit 2c2cab1e32e42cd59b5edee9b37dfd1c5946a9de.
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.

5 participants