TipcSrvConnGetTimeout


Name

TipcSrvConnGetTimeout — get a timeout property from the connection

Synopsis

T_BOOL TipcSrvConnGetTimeout(srv, timeout, value_return) 
T_IPC_SRV srv; 
T_IPC_TIMEOUT timeout; 
T_REAL8 *value_return; 

Arguments

srv — connection handle to RTServer

timeout — which timeout property to get

value_return — storage for timeout value

Return Values

TRUE if the timeout property was successfully retrieved from the connection to RTserver, FALSE otherwise.

Diagnostics

If TipcSrvConnGetTimeout fails, it returns FALSE and sets the global SmartSockets error number to one of:

Description

TipcSrvConnGetTimeout gets a timeout property from the connection to RTserver by calling TipcConnGetTimeout. The timeout properties control how often (in seconds) the connection to RTserver is checked for possible network failures. See TipcConnGetTimeout for more information on connection timeouts.

The timeout properties of the connection to RTserver are also available in the options Server_Read_Timeout, Server_Write_Timeout, Server_Keep_Alive_Timeout, and Server_Delivery_Timeout. For the connection to RTserver, the default read timeout is 30.0 seconds, the default write timeout is 30.0 seconds, the default keep alive timeout is 15.0 seconds, and the default delivery timeout is 30.0 seconds.

TipcSrvConnGetTimeout may attempt to automatically create a connection to RTserver. If RTclient has a warm connection to RTserver, TipcSrvConnGetTimeout gets a timeout property from the warm connection. See TipcSrvConnOpen for more information on automatic creation of connections and warm connections to RTserver.

Caution

If TipcSrvConnGetTimeout returns FALSE, it does not store a value in value_return.

See Also

TipcConnGetTimeout, TipcSrvConnSetTimeout

Examples

This example gets the read timeout from the connection to RTserver with TipcSrvConnGetTimeout and prints it:

T_IPC_SRV srv; 
T_REAL8 timeout; 
 
if (!TipcSrvConnGetTimeout(srv, T_IPC_TIMEOUT_READ, &timeout)) { 
  return;  /* error */ 
} 
 
TutOut("The connection to RTserver’s read timeout is %s 
seconds.\n",  
       TutRealToStr(timeout)); 

TIBCO SmartSockets™ Application Programming Interface
Software Release 6.8, July 2006
Copyright © TIBCO Software Inc. All rights reserved
www.tibco.com