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

Destination Databricks: replicate into specified catalog using three level namespace #20954

Closed

Conversation

mcfuhrt
Copy link

@mcfuhrt mcfuhrt commented Jan 2, 2023

What

The Problem and solution can be found in the corresponding Issue: #20953

Recommended reading order

  1. spec.json
  2. DatabricksDestinationConfig.java
  3. DatabricksStreamCopier.java
  4. DatabricksS3StreamCopier.java
  5. DatabricksS3StreamCopierFactory.java
  6. DatabricksAzureBlobStorageStreamCopier.java
  7. DatabricksAzureBlobStorageStreamCopierFactory.java
  8. DatabricksSqlOperations.java

🚨 User Impact 🚨

Are there any breaking changes? What is the end result perceived by the user? If yes, please merge this PR with the 🚨🚨 emoji so changelog authors can further highlight this if needed.

Pre-merge Checklist

Expand the relevant checklist and delete the others.

Updating a connector

Community member or Airbyter

  • [] Grant edit access to maintainers (instructions)
  • Secrets in the connector's spec are annotated with airbyte_secret
  • Unit & integration tests added and passing. Community members, please provide proof of success locally e.g: screenshot or copy-paste unit, integration, and acceptance test output. To run acceptance tests for a Python connector, follow instructions in the README. For java connectors run ./gradlew :airbyte-integrations:connectors:<name>:integrationTest.
  • Code reviews completed
  • Documentation updated
    • Connector's README.md
    • Connector's bootstrap.md. See description and examples
    • Changelog updated in docs/integrations/<source or destination>/<name>.md including changelog. See changelog example
  • PR name follows PR naming conventions

Airbyter

If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.

  • Create a non-forked branch based on this PR and test the below items on it
  • Build is successful
  • If new credentials are required for use in CI, add them to GSM. Instructions.
  • /test connector=connectors/<name> command is passing
  • New Connector version released on Dockerhub and connector version bumped by running the /publish command described here

Tests

Unit

Put your unit tests output here.

Integration

Put your integration tests output here.

Acceptance

Put your acceptance tests output here.

@mcfuhrt mcfuhrt marked this pull request as ready for review January 2, 2023 21:23
@mcfuhrt mcfuhrt requested a review from a team as a code owner January 2, 2023 21:23
@subodh1810 subodh1810 requested review from a team and removed request for a team February 6, 2023 09:01
Comment on lines 190 to 195
if (!useMetastore) {
queries.append(sqlOperations.copyTableQuery(database, String.format("%s.%s", catalogName, schemaName), tmpTableName, destTableName));
} else {
queries.append(sqlOperations.copyTableQuery(database, schemaName, tmpTableName, destTableName));
}
queries.append(sqlOperations.insertTableQuery(database, schemaName, tmpTableName, destTableName));
Copy link

Choose a reason for hiding this comment

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

I believe there should be insertTableQuery instead of copyTableQuery.

Copy link
Author

Choose a reason for hiding this comment

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

@IgSaf you were right, I fixed the call and remove the unnecessary one in line 195

@evantahler
Copy link
Contributor

@mcfuhrt can you please rebase this PR with the latest changes so we can test it out?

@evantahler
Copy link
Contributor

Closing due to lack of comment... and #24657 should also fix things

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

5 participants