hudi icon indicating copy to clipboard operation
hudi copied to clipboard

[MINOR]: Optimize the judgment logic of `SparkDataSourceOptions Key`

Open gnailJC opened this issue 2 years ago • 1 comments

Tips

  • Thank you very much for contributing to Apache Hudi.
  • Please review https://hudi.apache.org/contribute/how-to-contribute before opening a pull request.

What is the purpose of the pull request

HoodieSqlCommonUtils.withSparkConf() determines whether it is a hudi config key by judging the prefix hoodie., which will cause the as.of.instant configuration to be handled incorrectly. This PR is compatible with the judgment logic of as.of.instant.

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.

gnailJC avatar May 18 '22 02:05 gnailJC

@gnailJC can you please elaborate if this is addressing an issue that you've faced or is it just code cleanup?

alexeykudinkin avatar Sep 27 '22 20:09 alexeykudinkin

@gnailJC can you please elaborate if this is addressing an issue that you've faced or is it just code cleanup?

@alexeykudinkin this is reported in https://github.com/apache/hudi/issues/5586

This is not really a blocker; more of a usability with time travel, which can be mitigated as suggested in https://github.com/apache/hudi/issues/5586#issuecomment-1128319091

I updated the PR so that we can keep the compatibility for using this and filed https://issues.apache.org/jira/browse/HUDI-4935 for breaking change in 1.0.0

xushiyan avatar Sep 28 '22 05:09 xushiyan

CI report:

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

hudi-bot avatar Sep 28 '22 11:09 hudi-bot