googleapis / googleapis/google-cloud-php
[Spanner] Add back requestTimeout to Spanner v2
- Dominant language
- PHP
- Stars
- 1.2k
- Forks
- 463
- Avg merge
- 2d 1h
- Merged PRs (30d)
- 145
Description
Spanner v2 library removed the `requestTimeout` option from the client options but I would like to see this revived.
Currently there is no way to set a default timeout for all outgoing requests and it's been a major pain to go around and add the timeouts individually. I am constantly worried that I might forget to add a timeout when writing a query.
When I was looking for places to add the timeouts, I also noticed that some methods like `Operation::transaction()` and `Transaction::rollback()` do no mention that there is a timeout option when it should.
Then there is `SessionCache::refresh()` which calls an API when creating a new session but does not allow us to set a timeout.
Please let me know what you think.
Contributor guide
Assessment
This issue has not been assessed yet.