mirror of
https://github.com/lancedb/lancedb.git
synced 2026-01-10 05:42:58 +00:00
Provides the ability to set a timeout for merge insert. The default underlying timeout is however long the first attempt takes, or if there are multiple attempts, 30 seconds. This has two use cases: 1. Make the timeout shorter, when you want to fail if it takes too long. 2. Allow taking more time to do retries. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added support for specifying a timeout when performing merge insert operations in Python, Node.js, and Rust APIs. - Introduced a new option to control the maximum allowed execution time for merge inserts, including retry timeout handling. - **Documentation** - Updated and added documentation to describe the new timeout option and its usage in APIs. - **Tests** - Added and updated tests to verify correct timeout behavior during merge insert operations. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
27 lines
755 B
Markdown
27 lines
755 B
Markdown
[**@lancedb/lancedb**](../README.md) • **Docs**
|
|
|
|
***
|
|
|
|
[@lancedb/lancedb](../globals.md) / WriteExecutionOptions
|
|
|
|
# Interface: WriteExecutionOptions
|
|
|
|
## Properties
|
|
|
|
### timeoutMs?
|
|
|
|
```ts
|
|
optional timeoutMs: number;
|
|
```
|
|
|
|
Maximum time to run the operation before cancelling it.
|
|
|
|
By default, there is a 30-second timeout that is only enforced after the
|
|
first attempt. This is to prevent spending too long retrying to resolve
|
|
conflicts. For example, if a write attempt takes 20 seconds and fails,
|
|
the second attempt will be cancelled after 10 seconds, hitting the
|
|
30-second timeout. However, a write that takes one hour and succeeds on the
|
|
first attempt will not be cancelled.
|
|
|
|
When this is set, the timeout is enforced on all attempts, including the first.
|