Make overriding branch settings thread-safe LMS-11125