in reply to debugging POE and MySQL connections

POE seems like a red herring here. None of the POE modules you mentioned deals with databases, so you're looking at a straightforward DBI issue in a POE-based bot.

So I'd start by checking and logging the return values from your DBI calls, and graduate to reconnecting and retrying if they fail due to a dropped connection.

-- Rocco Caputo - http://poe.perl.org/

  • Comment on Re: debugging POE and MySQL connections

Replies are listed 'Best First'.
Re^2: debugging POE and MySQL connections
by bfdi533 (Friar) on Mar 31, 2006 at 19:16 UTC

    Thanks for the pointer; I had not thought about that.

    I dug further and found I could do the following and it would automatically reconnect:

    $dbh = DBI->connect("DBI:mysql:database=$dbname:$server", $username, $password); $dbh->{mysql_auto_reconnect} = 1;