gitlab-org--gitlab-foss/app/models
Dmitriy Zaporozhets 64c2bccdd9 Merge branch 'fix-issue-3067' into 'master'
Fix nonatomic database update potentially causing project star counts to go negative

The `counter_cache` decrement function is called when a project star is deleted,
but there was no guarantee multiple workers would not attempt to delete the
same item simultaneously. Use an atomic update to prevent the count from going negative.

Note: I was only able to duplicate the issue on GitLab.com, but I haven't been able to replicate it anywhere else. Presumably this bug happens when the `WHERE` clause takes some time to search for the right entry and multiple requests get sent simultaneously. Need to verify whether this fix truly solves the issue.

Closes #3067

See merge request !1628
2015-10-17 18:00:02 +00:00
..
ci Implement when syntax in .gitlab-ci.yml 2015-10-15 23:49:39 +02:00
concerns Merge branch 'master' into rs-redactor-filter 2015-10-16 11:26:48 +02:00
hooks enable SSL by default 2015-09-17 09:51:24 +03:00
members
network
project_services Improve invalidation of stored service password if the endpoint URL is changed 2015-10-15 12:07:59 +02:00
.gitkeep
ability.rb Added builds view 2015-10-14 17:28:38 +02:00
abuse_report.rb Streamline the "Report button" 2015-09-29 21:47:01 +02:00
application_setting.rb Remove the option to disable CI 2015-10-05 12:23:38 -04:00
audit_event.rb Re-annotate models 2015-08-03 01:52:54 +09:00
broadcast_message.rb
commit.rb Merge branch 'master' into rs-redactor-filter 2015-10-15 11:26:58 +02:00
commit_range.rb
commit_status.rb Implement when syntax in .gitlab-ci.yml 2015-10-15 23:49:39 +02:00
deploy_key.rb
deploy_keys_project.rb
diff_line.rb
email.rb
event.rb Create a "destroyed Milestone" event and keep Milestone events around in the DB 2015-09-15 05:51:11 -07:00
external_issue.rb
forked_project_link.rb
generic_commit_status.rb Implement Commit Status API 2015-10-12 11:53:49 +02:00
group.rb Eager load various issue/note associations 2015-10-15 12:05:01 +02:00
group_label.rb Allow dashboard and group issues/MRs to be filtered by label 2015-10-14 12:33:39 +02:00
group_milestone.rb Allow dashboard and group issues/MRs to be filtered by label 2015-10-14 12:33:39 +02:00
identity.rb Validate presence of provider field in Identity 2015-06-23 11:21:23 +02:00
issue.rb Re-annotate models 2015-09-06 07:48:48 -07:00
key.rb Only publish ssh key-type and key 2015-08-04 14:33:18 +02:00
label.rb Restore placeholders in issue filters from "Any" to "Milestone" and "Label" 2015-10-08 23:53:32 -07:00
label_link.rb
member.rb
merge_request.rb merge_request: add work_in_progress to MR hooks 2015-10-08 16:37:04 -04:00
merge_request_diff.rb Add a system note and update relevant merge requests when a branch is deleted or re-added 2015-10-15 23:54:13 -07:00
milestone.rb Restore placeholders in issue filters from "Any" to "Milestone" and "Label" 2015-10-08 23:53:32 -07:00
namespace.rb Fix: Images cannot show when projects' path was changed 2015-10-14 18:50:35 +03:00
note.rb Merge branch 'master' into rs-redactor-filter 2015-10-16 11:26:48 +02:00
notification.rb Added Global to the drop downs and updated the label of the button to show the current level instead of Notifications 2015-09-16 19:46:24 -05:00
personal_snippet.rb
project.rb Merge branch 'builds-view' into 'master' 2015-10-15 11:35:57 +00:00
project_import_data.rb
project_snippet.rb
project_team.rb Improve ProjectTeam#max_member_access performance 2015-10-15 12:05:01 +02:00
project_wiki.rb
protected_branch.rb
repository.rb Add system notes for restored branches 2015-10-15 23:54:13 -07:00
security_event.rb Re-annotate models 2015-08-03 01:52:54 +09:00
sent_notification.rb Merge branch 'master' into rename-reply-by-email 2015-09-21 10:35:56 +02:00
service.rb Improve invalidation of stored service password if the endpoint URL is changed 2015-10-15 12:07:59 +02:00
snippet.rb Make snippet filename optional. 2015-06-20 01:06:57 +02:00
subscription.rb
tree.rb
user.rb Fix nonatomic database update potentially causing project star counts to go negative 2015-10-17 00:58:14 -07:00
users_star_project.rb
wiki_page.rb