This PR should be replaced by #31860 in v1.23. The aim of creating this PR is to fix it in 1.22 because globallock hasn't been introduced. Fix #27640 Fix #29563 Fix #31215
state