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

fix: Persist missingValueInterpretationMap in StreamWriter's Builder #2587

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

yifatgortler
Copy link
Contributor

In case the StreamWriter is recreated, like during schema update, the map will be used in the new StreamWriter too.

@yifatgortler yifatgortler requested review from a team as code owners July 30, 2024 09:16
@product-auto-label product-auto-label bot added size: l Pull request size is large. api: bigquerystorage Issues related to the googleapis/java-bigquerystorage API. labels Jul 30, 2024
Copy link

conventional-commit-lint-gcf bot commented Jul 30, 2024

🤖 I detect that the PR title and the commit message differ and there's only one commit. To use the PR title for the commit history, you can use Github's automerge feature with squashing, or use automerge label. Good luck human!

-- conventional-commit-lint bot
https://conventionalcommits.org/

@yifatgortler yifatgortler requested review from GaoleMeng and yirutang and removed request for agrawal-siddharth July 30, 2024 09:16
@yifatgortler yifatgortler changed the title Persist missingValueInterpretationMap in StreamWriter's Builder fix: Persist missingValueInterpretationMap in StreamWriter's Builder Jul 30, 2024

/** @return the missing value interpretation map used for the writer. */
public Map<String, AppendRowsRequest.MissingValueInterpretation>
getMissingValueInterpretationMap() {
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we keep the get method?

@@ -105,6 +105,7 @@ private SchemaAwareStreamWriter(Builder<T> builder)
streamWriterBuilder.setLocation(builder.location);
streamWriterBuilder.setDefaultMissingValueInterpretation(
builder.defaultMissingValueInterpretation);
streamWriterBuilder.setMissingValueInterpretationMap(builder.missingValueInterpretationMap);
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's add a e2e test in the it directory?

Copy link

Warning: This pull request is touching the following templated files:

  • samples/install-without-bom/pom.xml
  • samples/snapshot/pom.xml
  • samples/snippets/pom.xml

…ase the StreamWriter is recreated, the map will be used in the new StreamWriter too.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquerystorage Issues related to the googleapis/java-bigquerystorage API. size: l Pull request size is large.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants