Maybe I'm missing something obvious but why Magento is storing database locks in a file system?
Storing them in a database instead will make it faster and will also resolve the clustering issue.
Any ideas?
Maybe I'm missing something obvious but why Magento is storing database locks in a file system?
Storing them in a database instead will make it faster and will also resolve the clustering issue.
Any ideas?
Normally you would use a lock when running scripts from the CLI. The only reason I can think of is that a file lock is released in case your script unexpectedly dies. This won't happen if you use a DB lock: you would have to manually release the lock.
It's actually very good question.
One reason I can think of is that if you run database intense stuff (such as reindexing, which creates those locks), getting an answer from the database could take considerably more time than checking for a semaphore file.