Hi Andrei,
From what I have seen in the code this is pretty useless (no offence).
The ping in this particular instance is only executed JUST before a real query is to be issued. i.e. if a query is not used in Kamailio for a couple of hours - the ping is actually never sent...........
what I have noticed is that when the connection is torn down by the firewall, the ping actually hangs (reconnect fails), etc
So, we NEED a proper ping (keepalive) functionality :D
Cheers
Jason
Doesn't modparam("db_mysql", "ping_interval", 15) work?On Sep 22, 2009 at 09:28, Jason Penton <jason.penton@smilecoms.com> wrote:
> Hi *,
>
> What would be the suggestions regarding having a process / thread that can
> be used to ping (keepalive) a connection to a particular db backend. I am
> specifically looking at coding something for mysql (our firewall is closing
> connections to mysql if they are idle for longer than 30mins). I would like
> to have a process that would go through all connections and "ping" them
> every so often. I would imagine each DB impl can either ignore the ping
> function or actually do something with it. I would imagine this will be
> useful for a few backend db implementations. Any input before I go ahead?
Andrei