Assuming the multiple applications use this statement to assure exclusivity with MySQL Locking Functions
SELECT IF(IS_USED_LOCK(:name) = CONNECTION_ID(), -1, GET_LOCK(:name, 0))
I'm wondering whether the IF statement is atomic (can it happen that lock gets acquired multiple times)