After update to 13.1.2(puma) from version 12.x.x(unicorn) creating merge request shows "Checking ability to merge automatically…" for up to 10 minutes
Summary
After updating to 13.1.2 & switching from unicorn to puma with it, when we open a merge request it started hanging in "Checking ability to merge automatically…" for too long. From 10 seconds to minutes.
While it is hanging there if we open another tab/window & check the merge request we can see that merge request long passed that check. See below:

Steps to reproduce
Following documentation (https://docs.gitlab.com/ee/install/requirements.html#puma-workers) we set "puma worker_process" to "cores -1". We can reproduce this %90 of the time on our test & productive instance. You just create a merge request & observe that "Checking ability to merge automatically…" stays there for up to 10-20 minutes. OR until you refresh the page.
& from time to time it behaves normal (e.g. shows the merge button immediately.), it can have something to do with the project size/# of commits but we are unable to verify it
What is the current bug behavior?
When we open a new merge request "Checking ability to merge automatically…" shows on the web page for too long, sometimes up to 10 minutes. When you refresh the page (e.g. immediately after creating the merge request) you can see that this message is not show & "merge button" is visible, so we assume it does not have something to do we background calculations but webserver.
What is the expected correct behavior?
When a new merge request is created "Checking ability to merge automatically…" should disappear after calculation is over, without refresh of the page
Relevant logs and/or screenshots
For a screenshot please see above - regarding logs we are unable to find anything suspicious entries in logs - if you believe we should check a specific log please specify
Output of checks
Results of GitLab environment info
Expand for output related to GitLab environment info
System information System: Current User: git Using RVM: no Ruby Version: 2.6.6p146 Gem Version: 2.7.10 Bundler Version:1.17.3 Rake Version: 12.3.3 Redis Version: 5.0.9 Git Version: 2.27.0 Sidekiq Version:5.2.7 Go Version: unknown GitLab information Version: 13.1.2 Revision: 2e7a6f64b07 Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: PostgreSQL DB Version: 11.7 URL: https://tst-gitlab.emcode.siemens.com HTTP Clone URL: https://tst-gitlab.emcode.siemens.com/some-group/some-project.git SSH Clone URL: git@tst-gitlab.emcode.siemens.com:some-group/some-project.git Using LDAP: yes Using Omniauth: no GitLab Shell Version: 13.3.0 Repository storage paths: - default: /data/gitlab/git/repositories GitLab Shell path: /opt/gitlab/embedded/service/gitlab-shell Git: /opt/gitlab/embedded/bin/git
Results of GitLab application Check
Expand for output related to the GitLab application check
Checking GitLab subtasks ...
Checking GitLab Shell ...
GitLab Shell: ... GitLab Shell version >= 13.3.0 ? ... OK (13.3.0) Running /opt/gitlab/embedded/service/gitlab-shell/bin/check Internal API available: OK Redis available via internal API: OK gitlab-shell self-check successful
Checking GitLab Shell ... Finished
Checking Gitaly ...
Gitaly: ... default ... OK
Checking Gitaly ... Finished
Checking Sidekiq ...
Sidekiq: ... Running? ... yes Number of Sidekiq processes ... 1
Checking Sidekiq ... Finished
Checking Incoming Email ...
Incoming Email: ... Reply by email is disabled in config/gitlab.yml
Checking Incoming Email ... Finished
Checking LDAP ...
LDAP: ... Server: ldapmain LDAP authentication... Success LDAP users with access to your GitLab server (only showing the first 100 results) User output sanitized. Found 100 users of 100 limit.
Checking LDAP ... Finished
Checking GitLab App ...
Git configured correctly? ... yes Database config exists? ... yes All migrations up? ... yes Database contains orphaned GroupMembers? ... no GitLab config exists? ... yes GitLab config up to date? ... yes Log directory writable? ... yes Tmp directory writable? ... yes Uploads directory exists? ... yes Uploads directory has correct permissions? ... yes Uploads directory tmp has correct permissions? ... yes Init script exists? ... skipped (omnibus-gitlab has no init script) Init script up-to-date? ... skipped (omnibus-gitlab has no init script) Projects have namespace: ... 30/1 ... yes 104/2 ... yes 30/7 ... yes 30/8 ... yes 2/10 ... yes 30/11 ... yes 2/15 ... yes 105/38 ... yes 33/40 ... yes 28/47 ... yes 57/48 ... yes 57/51 ... yes 104/57 ... yes 11/59 ... yes 2/61 ... yes 2/62 ... yes 83/63 ... yes 2/64 ... yes 2/65 ... yes 2/66 ... yes 2/68 ... yes 2/69 ... yes 67/74 ... yes 2/110 ... yes 106/111 ... yes 79/112 ... yes 79/121 ... yes 79/123 ... yes 2/124 ... yes 82/125 ... yes 2/130 ... yes 80/145 ... yes 74/147 ... yes 92/148 ... yes 93/149 ... yes 84/150 ... yes 94/151 ... yes 95/155 ... yes 77/156 ... yes 88/157 ... yes 78/158 ... yes 73/161 ... yes 75/163 ... yes 86/164 ... yes 94/165 ... yes 73/167 ... yes 73/169 ... yes 79/170 ... yes 106/171 ... yes 79/172 ... yes 99/180 ... yes 108/183 ... yes 108/184 ... yes 109/186 ... yes 110/189 ... yes 113/194 ... yes 102/199 ... yes 102/200 ... yes 102/201 ... yes 102/202 ... yes 102/203 ... yes 116/227 ... yes 30/228 ... yes 79/245 ... yes 121/246 ... yes 122/247 ... yes 123/248 ... yes 125/250 ... yes 126/251 ... yes 127/252 ... yes 116/254 ... yes 129/255 ... yes 124/258 ... yes 75/260 ... yes 130/261 ... yes 75/262 ... yes 75/263 ... yes 75/264 ... yes 75/266 ... yes 75/267 ... yes 75/269 ... yes 75/270 ... yes 75/275 ... yes 75/276 ... yes 75/277 ... yes 75/280 ... yes 75/281 ... yes 75/282 ... yes 75/283 ... yes 75/285 ... yes 75/286 ... yes 75/287 ... yes 75/288 ... yes 131/290 ... yes 132/293 ... yes 132/294 ... yes 107/295 ... yes 133/296 ... yes 134/297 ... yes 135/298 ... yes 136/299 ... yes 137/300 ... yes 75/301 ... yes 140/304 ... yes 141/306 ... yes 142/307 ... yes 143/309 ... yes 128/319 ... yes 144/320 ... yes 145/321 ... yes 75/322 ... yes 79/323 ... yes 545/336 ... yes 147/338 ... yes 75/341 ... yes 148/342 ... yes 75/344 ... yes 111/347 ... yes 110/348 ... yes 110/351 ... yes 128/352 ... yes 128/353 ... yes 115/354 ... yes 128/356 ... yes 75/359 ... yes 149/360 ... yes 148/361 ... yes 150/362 ... yes 99/363 ... yes 99/365 ... yes 114/368 ... yes 148/369 ... yes 151/372 ... yes 152/375 ... yes 109/378 ... yes 111/379 ... yes 154/380 ... yes 155/381 ... yes 155/382 ... yes 155/383 ... yes 156/384 ... yes 102/385 ... yes 157/388 ... yes 158/389 ... yes 159/390 ... yes 75/391 ... yes 160/392 ... yes 106/397 ... yes 27/398 ... yes 112/400 ... yes 108/403 ... yes 102/409 ... yes 109/420 ... yes 99/421 ... yes 99/423 ... yes 165/428 ... yes 99/429 ... yes 113/433 ... yes 2/437 ... yes 2/438 ... yes 2/442 ... yes 166/444 ... yes 166/446 ... yes 102/480 ... yes 119/481 ... yes 39/514 ... yes 430/518 ... yes 203/519 ... yes 202/520 ... yes 165/523 ... yes 27/525 ... yes 27/527 ... yes 119/528 ... yes 119/529 ... yes 119/530 ... yes 119/531 ... yes 117/533 ... yes 117/534 ... yes 117/535 ... yes 117/537 ... yes 117/538 ... yes 187/539 ... yes 186/540 ... yes 185/541 ... yes 184/542 ... yes 183/543 ... yes 182/544 ... yes 181/545 ... yes 180/546 ... yes 179/547 ... yes 430/548 ... yes 99/552 ... yes 99/562 ... yes 532/568 ... yes 102/569 ... yes 119/570 ... yes 371/596 ... yes 381/616 ... yes 381/617 ... yes 381/618 ... yes 381/619 ... yes 381/620 ... yes 381/621 ... yes 381/622 ... yes 381/623 ... yes 381/624 ... yes 381/625 ... yes 381/626 ... yes 162/627 ... yes 108/629 ... yes 540/631 ... yes 221/632 ... yes 370/635 ... yes 30/636 ... yes 102/637 ... yes 15/644 ... yes 371/646 ... yes 371/647 ... yes 102/648 ... yes 355/649 ... yes 370/650 ... yes 102/651 ... yes 371/652 ... yes 106/653 ... yes 370/657 ... yes 102/660 ... yes 371/665 ... yes 2/666 ... yes 83/671 ... yes 102/672 ... yes 2/673 ... yes 102/675 ... yes 82/676 ... yes 2/678 ... yes 391/679 ... yes 83/682 ... yes 544/684 ... yes 387/685 ... yes 371/686 ... yes 387/689 ... yes 540/690 ... yes 15/691 ... yes 104/692 ... yes 27/694 ... yes 540/695 ... yes 117/696 ... yes 400/700 ... yes 400/701 ... yes 400/702 ... yes 400/703 ... yes 400/704 ... yes 400/705 ... yes 400/706 ... yes 400/707 ... yes 400/708 ... yes 400/709 ... yes 400/710 ... yes 400/711 ... yes 400/712 ... yes 400/713 ... yes 400/714 ... yes 400/715 ... yes 400/716 ... yes 400/717 ... yes 400/718 ... yes 400/719 ... yes 400/720 ... yes 400/721 ... yes 400/722 ... yes 400/723 ... yes 400/724 ... yes 400/725 ... yes 400/726 ... yes 400/727 ... yes 400/728 ... yes 400/729 ... yes 400/730 ... yes 400/731 ... yes 400/732 ... yes 400/733 ... yes 400/734 ... yes 400/735 ... yes 400/736 ... yes 400/737 ... yes 400/738 ... yes 400/739 ... yes 400/740 ... yes 400/741 ... yes 400/742 ... yes 400/743 ... yes 400/744 ... yes 400/745 ... yes 400/746 ... yes 400/747 ... yes 400/748 ... yes 400/749 ... yes 400/750 ... yes 400/751 ... yes 400/752 ... yes 400/753 ... yes 400/754 ... yes 400/755 ... yes 400/756 ... yes 15/764 ... yes 403/765 ... yes 405/766 ... yes 89/767 ... yes 96/772 ... yes 114/773 ... yes 307/774 ... yes 87/775 ... yes 431/776 ... yes 431/777 ... yes 400/779 ... yes 400/780 ... yes 400/781 ... yes 431/782 ... yes 30/783 ... yes 102/784 ... yes 436/785 ... yes 83/789 ... yes 82/790 ... yes 79/791 ... yes 102/792 ... yes 110/793 ... yes 30/794 ... yes 86/795 ... yes 452/796 ... yes 459/797 ... yes 459/798 ... yes 459/799 ... yes 459/800 ... yes 459/801 ... yes 459/802 ... yes 460/803 ... yes 461/804 ... yes 462/805 ... yes 463/806 ... yes 464/807 ... yes 465/808 ... yes 466/809 ... yes 467/810 ... yes 468/811 ... yes 457/812 ... yes 457/813 ... yes 457/814 ... yes 457/815 ... yes 457/816 ... yes 457/817 ... yes 30/818 ... yes 477/821 ... yes 391/822 ... yes 481/823 ... yes 85/824 ... yes 500/825 ... yes 500/826 ... yes 500/827 ... yes 500/828 ... yes 500/829 ... yes 500/830 ... yes 500/831 ... yes 485/832 ... yes 485/833 ... yes 485/834 ... yes 485/835 ... yes 485/836 ... yes 485/837 ... yes 485/838 ... yes 485/839 ... yes 485/840 ... yes 485/841 ... yes 485/842 ... yes 485/843 ... yes 485/844 ... yes 485/845 ... yes 485/846 ... yes 496/847 ... yes 488/848 ... yes 489/849 ... yes 489/850 ... yes 487/851 ... yes 490/852 ... yes 491/853 ... yes 491/854 ... yes 492/855 ... yes 492/856 ... yes 492/857 ... yes 493/858 ... yes 493/859 ... yes 494/860 ... yes 494/861 ... yes 494/862 ... yes 495/863 ... yes 30/865 ... yes 502/867 ... yes 502/868 ... yes 502/869 ... yes 502/870 ... yes 502/871 ... yes 502/872 ... yes 502/873 ... yes 502/874 ... yes 502/875 ... yes 502/878 ... yes 502/879 ... yes 502/880 ... yes 481/881 ... yes 505/883 ... yes 506/884 ... yes 371/887 ... yes 400/890 ... yes 15/891 ... yes 497/894 ... yes 102/896 ... yes 302/897 ... yes 102/898 ... yes 390/899 ... yes 400/900 ... yes 400/901 ... yes 400/902 ... yes 371/903 ... yes 523/904 ... yes 30/905 ... yes 106/906 ... yes 119/907 ... yes 400/908 ... yes 400/909 ... yes 400/910 ... yes 400/911 ... yes 400/912 ... yes 400/913 ... yes 206/914 ... yes 565/917 ... yes 300/918 ... yes 431/919 ... yes 481/920 ... yes 436/921 ... yes 27/924 ... yes 574/927 ... yes 583/929 ... yes 580/930 ... yes 481/932 ... yes 481/933 ... yes 575/934 ... yes 15/936 ... yes 102/937 ... yes 592/938 ... yes 481/939 ... yes Redis version >= 4.0.0? ... yes Ruby version >= 2.5.3 ? ... yes (2.6.6) Git version >= 2.22.0 ? ... yes (2.27.0) Git user has default SSH configuration? ... yes Active users: ... 298 Is authorized keys file accessible? ... yes GitLab configured to store new projects in hashed storage? ... yes All projects are in hashed storage? ... yes
Checking GitLab App ... Finished
Checking GitLab subtasks ... Finished