Skip to content

fix(bigtable): fix TestRetryApplyBulk_OverallRequestFailure test interceptor - #20574

Merged
mutianf merged 3 commits into
googleapis:mainfrom
mutianf:fix-bigtable-retry-apply-bulk-test
Sep 24, 2026
Merged

mutianf merged 3 commits into
googleapis:mainfrom
mutianf:fix-bigtable-retry-apply-bulk-test

Conversation

@mutianf

@mutianf mutianf commented Sep 24, 2026

Copy link
Copy Markdown
Contributor

Summary

  • The stream interceptor's success branch (errCount >= 3) returned nil without calling handler(srv, ss), so the fake server never wrote any MutateRowsResponse entries.
  • The client received a clean gRPC stream with zero response entries for its one mutation and raised bigtable: missing entry result in MutateRows response.
  • Fixed by delegating to handler(srv, ss) on the success path, matching the pattern used by every other interceptor in retry_test.go.

Test plan

  • go test -run TestRetryApplyBulk_OverallRequestFailure -v -count=1 ./bigtable/ passes
  • go test -run TestRetryApplyBulk -v -count=1 ./bigtable/ — all bulk retry tests pass

The success branch of the stream interceptor returned nil without
calling handler(srv, ss), so the fake server never wrote any
MutateRowsResponse entries. The client received a clean stream
with zero entries for its one mutation and raised
"missing entry result in MutateRows response".

Delegate to handler(srv, ss) on the success path, matching the
pattern used by all other interceptors in retry_test.go.

Change-Id: I7eff0cbabb511ebae2a3480d18de4eda862d6922
@mutianf
mutianf requested review from a team as code owners September 24, 2026 21:15
@product-auto-label product-auto-label Bot added the api: bigtable Issues related to the Bigtable API. label Sep 24, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

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.

Code Review

This pull request refactors the errInjector function in bigtable/retry_test.go to simplify the error injection logic. The review identifies a critical bug where the fallback handler call incorrectly passes ctx instead of the required srv interface, which would lead to a runtime panic.

Comment thread bigtable/retry_test.go
Change-Id: I088191725972d2948231885ae0ea58d0b4a9926e
@mutianf
mutianf merged commit 25bc085 into googleapis:main Sep 24, 2026
19 checks passed
@mutianf
mutianf deleted the fix-bigtable-retry-apply-bulk-test branch September 24, 2026 21:38
mutianf pushed a commit that referenced this pull request Sep 25, 2026
🤖 I have created a release *beep* *boop*
---


##
[1.58.0](bigtable/v1.57.0...bigtable/v1.58.0)
(2026-09-25)


### Features

* **all:** Update supported go versions
([#20520](#20520))
([90413d3](90413d3))
* **bigtable:** Support hot duration, disabled, and effective backup
policy
([#20573](#20573))
([da2bfcc](da2bfcc))
* Update API sources and regenerate
([#20526](#20526))
([e6f37a3](e6f37a3))
* Update API sources and regenerate
([#20570](#20570))
([cc91d66](cc91d66))
* Update API sources and regenerate.
([e6f37a3](e6f37a3))


### Bug Fixes

* **bigtable:** Detect omitted MutateRows response entries in ApplyBulk
([#20557](#20557))
([68b3f33](68b3f33))
* **bigtable:** Fix TestRetryApplyBulk_OverallRequestFailure test
interceptor
([#20574](#20574))
([25bc085](25bc085))
* **various:** Address format directive issues
([#20547](#20547))
([e2e1047](e2e1047))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: bigtable Issues related to the Bigtable API.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants