Skip to content

feat(bigquery): set PreferredMinStreamCount when creating read session#8476

Merged
gcf-merge-on-green[bot] merged 5 commits intogoogleapis:mainfrom
alvarowolfx:bq-storage-read-preferred-stream-count
Aug 30, 2023
Merged

feat(bigquery): set PreferredMinStreamCount when creating read session#8476
gcf-merge-on-green[bot] merged 5 commits intogoogleapis:mainfrom
alvarowolfx:bq-storage-read-preferred-stream-count

Conversation

@alvarowolfx
Copy link
Copy Markdown
Contributor

PreferredMinStreamCount must be less than or equal to MaxStreamCount, so we only set it when the MaxStreamCount is 0, which basically sets no limit to it.

Resolves #8432

@alvarowolfx alvarowolfx requested review from a team and shollyman August 23, 2023 21:22
@product-auto-label product-auto-label bot added size: xs Pull request size is extra small. api: bigquery Issues related to the BigQuery API. labels Aug 23, 2023
Copy link
Copy Markdown
Contributor

@shollyman shollyman left a comment

Choose a reason for hiding this comment

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

minor nit, but otherwise LGTM

Comment thread bigquery/storage_client.go Outdated

// Start initiates a read session
func (rs *readSession) start() error {
preferredMinStreamCount := int32(0)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

this looks a bit odd, why not just var preferredMinStreamCount int32?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

good point, let me change here. I think I was playing with default values and ended up leaving like that.

@alvarowolfx alvarowolfx added the automerge Merge the pull request once unit tests and other checks pass. label Aug 30, 2023
@gcf-merge-on-green gcf-merge-on-green bot merged commit 22e095a into googleapis:main Aug 30, 2023
@gcf-merge-on-green gcf-merge-on-green bot removed the automerge Merge the pull request once unit tests and other checks pass. label Aug 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: bigquery Issues related to the BigQuery API. size: xs Pull request size is extra small.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bigquery: set PreferredMinStreamCountwhile creating CreateReadSessionRequest

2 participants