Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HUDI-2491 hoodie.datasource.hive_sync.mode=hms mode is supported in s… #3722

Closed
wants to merge 2 commits into from

Conversation

fuyun2024
Copy link
Contributor

…park writer option

Tips

What is the purpose of the pull request

(For example: This pull request adds quick-start document.)

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

hudi-bot commented Sep 26, 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

@nsivabalan
Copy link
Contributor

@codope : Can you take up this review please.

@nsivabalan nsivabalan self-assigned this Oct 7, 2021
@fuyun2024
Copy link
Contributor Author

@nsivabalan Thank you for your comments, but I don't know where the mistake is. I'm a novice

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.

@fuyun2024 Thanks for the contribution. It will be a useful addition to the hive sync. Could you please address some of the comments?

@@ -381,6 +381,11 @@ object DataSourceWriteOptions {
val HIVE_URL: ConfigProperty[String] = ConfigProperty
.key("hoodie.datasource.hive_sync.jdbcurl")
.defaultValue("jdbc:hive2://localhost:10000")
.withDocumentation("Hive jdbc url")

val METASTOR_URIS: ConfigProperty[String] = ConfigProperty
Copy link
Member

Choose a reason for hiding this comment

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

Minor: rename to METASTORE_URI

.withDocumentation("Hive jdbc url")

val METASTOR_URIS: ConfigProperty[String] = ConfigProperty
.key("hoodie.datasource.hive_sync.metastore.uris")
Copy link
Member

Choose a reason for hiding this comment

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

Let's have consistency with DeltaStreamer. There should be a way to set this config with deltastreamer as well.

Copy link
Member

Choose a reason for hiding this comment

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

Perhaps we need to set this config in DataSourceUtils#buildHiveSyncConfig. Please check.

@@ -517,6 +517,9 @@ object HoodieSparkSqlWriter {
val hiveSyncConfig: HiveSyncConfig = buildSyncConfig(basePath, hoodieConfig, sqlConf)
val hiveConf: HiveConf = new HiveConf()
hiveConf.addResource(fs.getConf)
if(!DataSourceWriteOptions.METASTOR_URIS.defaultValue.equals(hiveSyncConfig.metastoreUris)){
Copy link
Member

Choose a reason for hiding this comment

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

Can you please add a test case in the writer test suite or elsewhere to cover this scenario?

@fuyun2024 fuyun2024 closed this Oct 14, 2021
@fuyun2024 fuyun2024 deleted the HUDI-2491 branch October 14, 2021 08:22
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.

None yet

4 participants