I'm not sure to get it. i can add the lock flag on file_put_contents but I'm running equivalent code on pretty high load server without any problems.