[TECH-SUPPORT] LPS-43611 Inline resource permission checker is slow on MySQL

Hi Vili,

If you found this PR right, plz forward it to Shuyang and CC Ray.

Thanks,
Laci.