ewdb_base_ConnMgr()

Prototype:
thr_ret ewdb_base_ConnMgr( void * dummy);
Description: The connection manager thread. This thread runs periodically and brings the connection to the DB down if it has timed out(been inactive for a certain amount of time.) By having a connection manager, the DB connection can be left open in between consecutive DB calls, yet still closed when not in use. The idea behind the connection mgr is to optimize the efficiency of accessing the DB, relative to limiting the use of DB licenses and the overhead time required to raise a DB connection.

RETURN CODE INFO
Return Type: thr_ret

PARAMETER INFO
Parameter Type Description
dummy void * Default parameter. Unused by this function.

Group: EWDB_API_LIB
Sub Group: EWDB_BASE
Language: C
Location: ./src/oracle/schema-working/src/include/internal/ewdb_ew_oci_base.h



ewdb_base_SetLastOraAPIActionTime()

Prototype:
void ewdb_base_SetLastOraAPIActionTime( void);
Description: Sets the time of the last ora_api action call to NOW. The connection manager will close the connection to the database EWDB_MAX_IDLE_TIME seconds after the last API call action.

RETURN CODE INFO
Return Type: void

PARAMETER INFO

Group: EWDB_API_LIB
Sub Group: EWDB_BASE
Language: C
Location: ./src/oracle/schema-working/src/include/internal/ewdb_ew_oci_base.h



ewdb_base_SetOraConnectionTimeout()

Prototype:
void ewdb_base_SetOraConnectionTimeout( int tsec);
Description: Sets the connection timeout, so that the connection manager will not close the database connection until NOW + tsec seconds. This call is useful if you know that a database call will take a long time. DeleteEvent() is an excelent example. The DB connection may timeout if you simply use ewdb_base_SetLastOraAPIActionTime(), whereas you can call ewdb_base_SetOraConnectionTimeout() to set the timeout to 15 minutes, so that you don't get a disconnect during the delete. You can then call ewdb_base_SetOraConnectionTimeout() after the DB call has executed in order to reset the timeout to normal.

RETURN CODE INFO
Return Type: void

PARAMETER INFO
Parameter Type Description
tsec int The number of seconds from now that the connection manager should timeout the connection and close it. (Should obviously be > 0)

Group: EWDB_API_LIB
Sub Group: EWDB_BASE
Language: C
Location: ./src/oracle/schema-working/src/include/internal/ewdb_ew_oci_base.h



ewdb_base_TerminateConnMgr()

Prototype:
void ewdb_base_TerminateConnMgr( void);
Description: Causes the connection manager to shutdown. It may take a couple of seconds for the connection manager to shutdown if it is currently asleep. Should only be called when terminating use of the DB and API code. It SHOULD NOT be called by individual functions when they are finished using the DB.

RETURN CODE INFO
Return Type: void

PARAMETER INFO

Group: EWDB_API_LIB
Sub Group: EWDB_BASE
Language: C
Location: ./src/oracle/schema-working/src/include/internal/ewdb_ew_oci_base.h