Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix close issue but time watcher still running (#17643) #17761

Merged
merged 2 commits into from
Nov 23, 2021

Conversation

lunny
Copy link
Member

@lunny lunny commented Nov 22, 2021

back port from #17643

@lunny lunny added the type/bug label Nov 22, 2021
@lunny lunny added this to the 1.15.7 milestone Nov 22, 2021
@GiteaBot GiteaBot added the lgtm/need 1 This PR needs approval from one additional maintainer to be merged. label Nov 22, 2021
models/issue_stopwatch.go Outdated Show resolved Hide resolved
Co-authored-by: zeripath <art27@cantab.net>
@lunny
Copy link
Member Author

lunny commented Nov 23, 2021

@zeripath done.

@zeripath
Copy link
Contributor

Do we need to fix main too?

@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Nov 23, 2021
@zeripath
Copy link
Contributor

There are many ways in which races resulting in a double stopwatches could still happen here.

Realistically the decision to finish or open a new stopwatch should be done within a transaction with select for updates etc.

However this is a backport and this is just yet another example of easily induceable inconsistency under load.

We have to address this at some point though.

@lunny lunny merged commit 714ecd9 into go-gitea:release/v1.15 Nov 23, 2021
@lunny lunny deleted the lunny/fix_issue_close_bug2 branch November 23, 2021 12:05
@zeripath zeripath changed the title Fix close issue but time watcher still running Fix close issue but time watcher still running (#17643) Dec 2, 2021
@go-gitea go-gitea locked and limited conversation to collaborators Apr 28, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. type/bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants