Skip to content

box: fix box.commit({wait = 'none'}) could yield#11314

Merged
sergepetrenko merged 1 commit intotarantool:masterfrom
nshy:gh-11224-fix-box-commit-wait-none
Apr 10, 2025
Merged

box: fix box.commit({wait = 'none'}) could yield#11314
sergepetrenko merged 1 commit intotarantool:masterfrom
nshy:gh-11224-fix-box-commit-wait-none

Conversation

@nshy
Copy link
Contributor

@nshy nshy commented Mar 28, 2025

The issue is in order to decide whether submitting request to journal would yield or not we check the journal queue size. But the size can be less then limit while queue is not empty. At this moment submitting new request will yield.

Closes #11224

@nshy nshy requested a review from a team as a code owner March 28, 2025 14:47
@coveralls
Copy link

coveralls commented Mar 28, 2025

Coverage Status

coverage: 87.471% (-0.02%) from 87.486%
when pulling 786004b on nshy:gh-11224-fix-box-commit-wait-none
into 061d4bb
on tarantool:master
.

Copy link
Collaborator

@sergepetrenko sergepetrenko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for finding and fixing this!
LGTM.

@sergepetrenko
Copy link
Collaborator

Let's also ask @Gerold103 to take a look.

Copy link
Collaborator

@Gerold103 Gerold103 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the patch! Huh, it was really an unexpected bug in such a simple place!

@nshy nshy force-pushed the gh-11224-fix-box-commit-wait-none branch from 0c4f690 to cf3e457 Compare April 4, 2025 10:13
The issue is in order to decide whether submitting request to journal
would yield or not we check the journal queue size. But the size can be
less then limit while queue is not empty. At this moment submitting
new request will yield.

Closes tarantool#11224

NO_DOC=bugfix
@nshy nshy force-pushed the gh-11224-fix-box-commit-wait-none branch from cf3e457 to 786004b Compare April 4, 2025 10:22
Copy link
Collaborator

@Gerold103 Gerold103 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, @nshy! The test is especially clean and nice, I like it ❤️.

@nshy nshy assigned sergepetrenko and unassigned Gerold103 Apr 8, 2025
@sergepetrenko sergepetrenko added full-ci Enables all tests for a pull request backport/3.2 Automatically create a 3.2 backport PR backport/3.3 Automatically create a 3.3 backport PR labels Apr 8, 2025
@sergepetrenko sergepetrenko merged commit c580f3a into tarantool:master Apr 10, 2025
58 of 82 checks passed
@TarantoolBot
Copy link
Collaborator

Successfully created backport PR for release/3.2:

@TarantoolBot
Copy link
Collaborator

Successfully created backport PR for release/3.3:

@TarantoolBot
Copy link
Collaborator

Backport summary

@nshy nshy deleted the gh-11224-fix-box-commit-wait-none branch April 28, 2025 09:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport/3.2 Automatically create a 3.2 backport PR backport/3.3 Automatically create a 3.3 backport PR full-ci Enables all tests for a pull request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

box.commit(wait = 'none') may yield

6 participants