Hi Folks,
I am having problems trying to use the GET_LOCK and IS_FREE_LOCK
commands. I am trying to put together a queue manager. The theory is
that is would scan for queues, check for a lock and if the lock if free
then start the queue. When the queue process starts it should use
GET_LOCK to acquire a lock so that when the queue manager does another
pass IS_FREE_LOCK would return false and the manager would know the
queue is running. Also if the queue dies, the lock would be released
and the manager could restart it.
My problem is that the IS_FREE_LOCK always returns true.
I have done some testing with two instances of the Query Browser
running. In one I execute:
SELECT GET_LOCK('testing',10)
> 1
In the second I execute :
SELECT IS_FREE_LOCK('testing');
> 1
Maybe I have misinterpreted the scope of the lock functions, my
understanding was that the GET_LOCK should create a lock and the lock
should remain until a RELEASE_LOCK command is issued or the process that
created it terminates, is this correct ? If this is true anybody got
any ideas why the IS_FREE_LOCK is always true ?
TIA,
JC
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]