Add missing lock in model cleanup

parent 54210884
Pipeline #3365 passed with stage
in 21 minutes and 14 seconds