Skip to content

Support timeout / retry on Table.read_row() #941

@mwarkentin

Description

@mwarkentin

Is your feature request related to a problem? Please describe.

We recently experienced an issue where a small number of requests to BigTable using Table.read_row() hung until we hit the default 60s timeout. This caused issues with our application including the kafka consumer being kicked out of the consumer group after not responding for 30s.

We want to set a more aggressive timeout for this function call (eg. less than 30 seconds) however we haven't been able to figure out a way - read_row() does not seem to support either timeout or retry args which are the documented ways to set a timeout on a request.

Describe the solution you'd like

Support table.read_row("keyid", timeout=5)

Alternatively, support setting a new global default timeout via environment variable or config file.

Describe alternatives you've considered

Perhaps we could refactor our code to use read_rows() instead and fetch a single row, but this feels hacky.

Additional context

Metadata

Metadata

Assignees

Labels

api: bigtableIssues related to the googleapis/python-bigtable API.priority: p3Desirable enhancement or fix. May not be included in next release.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions