Document `box_sequence_` C API functions
Nobody has claimed this yet.
- Dominant language
- CSS
- Stars
- 15
- Forks
- 49
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 3
Description
Product: Tarantool
Since: 1.7.6
Root document: https://www.tarantool.io/en/doc/latest/reference/reference_capi/box/
Details
The following public C API functions are missing in the documentation:
int box_sequence_next(uint32_t seq_id, int64_t *result)
int box_sequence_set(uint32_t seq_id, int64_t value)
int box_sequence_reset(uint32_t seq_id)
Suggested description
int box_sequence_next(uint32_t seq_id, int64_t *result)
Since version 1.7.6. Generate the next value of the specified sequence and update the sequence state accordingly.
Parameters:
seq_id (uint32_t)– sequence identifierresult (int64_t *)– pointer to a variable where the next sequence value will be stored on success
Returns:
0 on success and -1 otherwise. In case of an error, you can get more details via box_error_last().
int box_sequence_set(uint32_t seq_id, int64_t value)
Since version 1.7.6. Set the specified sequence to the given value.
Parameters:
seq_id (uint32_t)– sequence identifiervalue (int64_t)– the value to set the sequence to
Returns:
0 on success and -1 otherwise. In case of an error, you can get more details via box_error_last().
int box_sequence_reset(uint32_t seq_id)
Since version 1.7.6. Reset the specified sequence to its initial state.
If called outside of an active transaction, this function starts and commits one internally.
Parameters:
seq_id (uint32_t)– sequence identifier
Returns:
0 on success and -1 otherwise. In case of an error, you can get more details via box_error_last().
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Open the referenced C API root document and search for the existing sequence documentation and the three function names. Add entries for box_sequence_next(), box_sequence_set(), and box_sequence_reset() using the supplied signatures, parameters, return values, and transaction behavior; done means all three appear in the generated reference.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 55/100