Skip to content

Work around deadlocks in CI in admin_settings_spec.rb

Stan Hu requested to merge sh-fix-issue-471622 into master

What does this MR do and why?

It appears that on occasion Rails can get into a deadlock when attempting to clear the query cache from both the main and CI database (https://github.com/rails/rails/issues/45994). This was happening in ee/spec/features/admin/admin_settings_spec.rb because a project was created while the browser sent Ajax requests to the API, causing an update to the users activity while the project attempted to create a CI project mirror.

To work around the issue, fix the test to create the objects before loading the page.

Relates to #471622 (closed)

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Haven't been able to reproduce the issue in CI yet, since the timing has to be right.

Edited by Stan Hu

Merge request reports

Loading