Is there a timeout in ITConnection::Open() ?
Posted in 2003
Topics: Security, Permissions & Auditing
Hello I'm using Informix Dynamic Server 9.30 and Informix Client SDK 2.80. When the server is down if I call to ITConnection::Open(), it takes more or less 2.5 minutes before it returns. Is there any way to set a lower timeout in ITConnection::Open() ? Thank you very much in advance. ITDBInfo dbInfo; dbInfo.SetSystem("my_system"); dbInfo.SetDatabase("my_db"); dbInfo.SetUser("my_user"); dbInfo.SetPassword("my_pwd"); ITConnection connection; if(!connection.Open(dbInfo)) { cerr << "error in connection.Open" << endl; }
Enric Granda wrote: > I'm using Informix Dynamic Server 9.30 and Informix Client SDK 2.80. > When the server is down if I call to ITConnection::Open(), it takes > more or less 2.5 minutes > before it returns. > Is there any way to set a lower timeout in ITConnection::Open() ? > > Thank you very much in advance. > > > ITDBInfo dbInfo; > dbInfo.SetSystem("my_system"); > dbInfo.SetDatabase("my_db"); > dbInfo.SetUser("my_user"); > dbInfo.SetPassword("my_pwd"); > > ITConnection connection; > if(!connection.Open(dbInfo)) > { > cerr << "error in connection.Open" << endl; > } You can try setting the environment variables such as IFM*X_CONN_RETRY and IFM*X_CONN_TIMEOUT -- I can't remember if there's an M in the variable names. That's about all, though. -- Jonathan Leffler #include <disclaimer.h> Email: jleffler@earthlink.net, jleffler@us.ibm.com Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/