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

feat: Support gRPC Compression #2197

Merged
merged 6 commits into from Jul 21, 2023
Merged

feat: Support gRPC Compression #2197

merged 6 commits into from Jul 21, 2023

Conversation

yifatgortler
Copy link
Contributor

@yifatgortler yifatgortler commented Jul 20, 2023

Enable gRPC compression when a compressor name is provided to JsonStreamWriter/StreamWriter.
Only gzip compression is supported at the moment.

Please note that while it will reduce the network usage, it will increase CPU usage. Please verify the trade off per use case.

@yifatgortler yifatgortler requested a review from a team as a code owner July 20, 2023 05:12
@product-auto-label product-auto-label bot added size: m Pull request size is medium. api: bigquerystorage Issues related to the googleapis/java-bigquerystorage API. labels Jul 20, 2023
@yifatgortler yifatgortler changed the title Support gRPC Compression feat: Support gRPC Compression Jul 20, 2023
Copy link
Contributor

@yirutang yirutang left a comment

Choose a reason for hiding this comment

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

Thanks for getting this fixed!

Preconditions.checkNotNull(compressorName);
Preconditions.checkArgument(
compressorName.equals("gzip"),
"Compression of type \"%s\" isn't supported, only \"gzip\" compression is supported.",
Copy link
Contributor

Choose a reason for hiding this comment

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

Only check it at the bottom layer (ConnectionWorker) is enough?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed from JsonStreamWriter and SchemaAwareStreamWriter, and left it in StreamWriter. Verified that it's what we usually do.

@Neenu1995 Neenu1995 added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jul 20, 2023
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jul 20, 2023
@yirutang yirutang added the owlbot:run Add this label to trigger the Owlbot post processor. label Jul 21, 2023
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Jul 21, 2023
@yirutang yirutang merged commit 642e345 into googleapis:main Jul 21, 2023
17 checks passed
gcf-merge-on-green bot pushed a commit that referenced this pull request Jul 24, 2023
🤖 I have created a release *beep* *boop*
---


## [2.41.0](https://togithub.com/googleapis/java-bigquerystorage/compare/v2.40.1...v2.41.0) (2023-07-24)


### Features

* Add enable connection pool to sample ([#2192](https://togithub.com/googleapis/java-bigquerystorage/issues/2192)) ([c2642de](https://togithub.com/googleapis/java-bigquerystorage/commit/c2642de07556381490c92eedf25b17d36218c2f8))
* Support gRPC Compression ([#2197](https://togithub.com/googleapis/java-bigquerystorage/issues/2197)) ([642e345](https://togithub.com/googleapis/java-bigquerystorage/commit/642e3452f3b490d6d85b61dfd1a1bb82e175d565))


### Bug Fixes

* Reduce StreamConnection visibility since it is not supposed to be public. ([#2196](https://togithub.com/googleapis/java-bigquerystorage/issues/2196)) ([addbcdf](https://togithub.com/googleapis/java-bigquerystorage/commit/addbcdf04e330a76e29e41b1e8f4ca04ad96ed00))
* Update SchemaAwareStreamWriter comment to down recommend it. ([#2195](https://togithub.com/googleapis/java-bigquerystorage/issues/2195)) ([4897c05](https://togithub.com/googleapis/java-bigquerystorage/commit/4897c05aeb7cddff20fb530d64034cc143c24d91))


### Dependencies

* Update dependency com.google.cloud:google-cloud-bigquery to v2.30.1 ([#2191](https://togithub.com/googleapis/java-bigquerystorage/issues/2191)) ([da4f2e5](https://togithub.com/googleapis/java-bigquerystorage/commit/da4f2e5e801daad1136eb4a3e753e486cef194e7))
* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.13.1 ([#2199](https://togithub.com/googleapis/java-bigquerystorage/issues/2199)) ([fc8f4fb](https://togithub.com/googleapis/java-bigquerystorage/commit/fc8f4fbae333db08ae21730a61a8993c3e1f9897))

---
This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please).
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: m Pull request size is medium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants