List:General Discussion« Previous MessageNext Message »
From:André Ress Date:July 31 2006 7:58am
Subject:Re: Threads of terminated clientapplications
View as plain text  
I found a parameter called TimeBetweenWatchDogCheck for a MySql Cluster.
Could you give an example for not clustered MySql servers?
Info: Our application is not a webbased one.

Regards,
André
-----Ursprüngliche Nachricht-----
Von: Dan Nelson [mailto:dnelson@stripped] 
Gesendet: Freitag, 28. Juli 2006 19:00
An: André Ress
Cc: mysql@stripped
Betreff: Re: Threads of terminated clientapplications

In the last episode (Jul 28), André Ress said:
> We have a problem with abortet clients and long time querys. 
> 
> If our application performs a long time select statement on the mySql
> database and the application is abortet, the query still runs!  We
> tried several time-out variables like wait_timeout,
> interactive_timeout or connection_timeout but without success.  What
> we need is, that the connection thread gets terminated after the
> client application was abnormaly terminated.  We currently use a
> mySQL V5.0.20 server and have the problem under windows and linux os.
>
> Terminating the thread with KILL is not possible option, it has to be
> terminated automatically.

You might want to file an enhancement bugreport on this.  It would
probably require a watchdog mysqld thread that does a select() or
poll() on all active client connections periodically (every 60 seconds
or so?) to see whether they have been closed at the remote end, and if
they have, it sends a kill to the thread currently running a query.

Note that if your application is a web-based one, you will also have to
do this check yourself (i.e. poll the browser socket so you know when
they have hit the Stop button, and if they have, then close your
connection to the database).

-- 
	Dan Nelson
	dnelson@stripped




Thread
Threads of terminated clientapplicationsAndré Ress28 Jul
  • Re: Threads of terminated clientapplicationsDan Nelson28 Jul
Re: Threads of terminated clientapplicationsAndré Ress31 Jul
  • Re: Threads of terminated clientapplicationsDan Nelson31 Jul