List:MySQL++« Previous MessageNext Message »
From:Martin Dubuc Date:July 20 2010 2:17pm
Subject:Problem with ReconnectOption on CentOS 5.5
View as plain text  
I am running an application on both CentOS 5.5 and Fedora 13. CentOS 5.5
uses mysql-5.0.77-4 and Fedora 13 uses mysql-5.1.47.

I need to be able to auto-reconnect. My application executes the following
code when setting up a connection:

mysqlpp::Connection connection(false);

if (!connection.set_option(new mysqlpp::ReconnectOption(true))) {
    // Error handling
}

if (!connection.connect(DB_NAME, DB_HOST, DB_USER, DB_PASSWORD)) {
        // Error handling
}

This code used to work on both CentOS 5.4 (mysql-5.0.77-3) and Fedora 13
when using the 3.0.9 version of mysql++, but since I upgraded to mysql++
3.1.0 and CentOS 5.5, the connect call fails with error "Option can only be
set while the connection is established" on CentOS 5.5, although it works on
Fedora 13.

Martin

Thread
Problem with ReconnectOption on CentOS 5.5Martin Dubuc20 Jul
  • Re: Problem with ReconnectOption on CentOS 5.5Warren Young20 Jul
    • Re: Problem with ReconnectOption on CentOS 5.5Martin Dubuc20 Jul
      • Re: Problem with ReconnectOption on CentOS 5.5Warren Young20 Jul
        • Does 3.1.0 support MySQL 5.0?dancook)22 Jul
          • Re: Does 3.1.0 support MySQL 5.0?Warren Young22 Jul
            • RE: Does 3.1.0 support MySQL 5.0?dancook)23 Jul
              • Re: Does 3.1.0 support MySQL 5.0?Warren Young23 Jul