tarantool / tarantool/doc

Ability to set timeout for transactions was implemented

Open Beginner friendly
#2,401 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

2.10 feature reference server
Dominant language
CSS
Stars
15
Forks
49
Avg merge
1d 13h
Merged PRs (30d)
3

Description

Product: Tarantool
Since:
Root document: https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_txn_management/begin/
https://www.tarantool.io/en/doc/latest/dev_guide/reference_capi/txn/
SME: @ EvgenyMekhanik
Peer reviewer:

Details

Previously transactions are never closed until commit or rollback.
Timeout for transactions was implemented after which they are rolled
back. For these purpose, in box.begin the optional table parameter
was added. For example if user want to start transaction with timeout
3s, he should use box.begin({timeout = 3}). Also was implement new
configuration option box.cfg.txn_timeout which determines timeout for
transactions, for which the timeout was not explicitly set. By default
this option is set to infinity (TIMEOUT_INFINITY = 365 * 100 * 86400).
Also in C API was added new function to set timeout for transaction -
box_txn_set_timeout.
Requested by @EvgenyMekhanik in https://github.com/tarantool/tarantool/commit/a76eb6ef5fbd136352d01d8e62c1e8429979201a.

To-Do

  • Add timeout parameter to the description of box.begin
  • Add box_txn_set_timeout here

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked box.begin reference and C API transaction documentation. Add the documented timeout parameter for box.begin and the box_txn_set_timeout entry, then verify both pages explain the implemented behavior and link correctly.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, lua
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.