Specifying the database connection (DB.Connects) log entry type turns on logging of database connections (connects and disconnects) in the client log. (For information on configuring and enabling logging, see Logging infrastructure overview.) The log messages include database name and user ID number. Information is logged at logging level 2 (basic) and higher.

Log entries generated for this type contain the tag CONN. An example of database connection logging messages (with headers suppressed) is shown:

CONN           Database sports2020 Options:  (12699)
CONN           Connected to database sports2020, user number 5. (9543)
...
CONN           Disconnecting from database sports2020, user number 5. (9545)

The default for the application server is ASPlumbing and DB.Connects. Generally, these log entry types are together in an application server log. For example:

-- Log entry types activated: ASPlumbing,DB.Connects
AS Starting MSAS Session for oepas1.
AS MSAS Session Startup. (5473)
MSAS Incremented connection count for sports2020 (sports2020): 1
CONN           Database sports2020 Options:  (12699)
CONN           Connected to database sports2020, user number 5. (9543)
...
MSAS Agent Shutting Down. Status: 4020
MSAS Worker Thread exiting. Number: 5, Status: 0
MSAS Disconnecting resource manager sports2020 (sports2020).
CONN           Disconnecting from database sports2020, user number 5. (9545)
MSAS Removed connection sports2020 from session 2.
MSAS Agent Shutdown Complete.

Logging for database connection control parameters

If you are using database connection control parameters (-dbalt1 or -dbalt2) to specify alternate databases to connect to, additional messages are logged. (For more information, see Learn about automatic database reconnect.)

At logging level 2 (basic) or higher, upon successful connection to an alternate database, a message is logged indicating the connection is to an alternate:
CONN           Connected to alternate database alt2
At logging level 3 (verbose) or higher, messages are logged showing the attempted connections:
CONN           Attempting to connect to database prim (primary)
CONN           Failed to connect to database prim
CONN           Failover: attempting to connect to database alt1 (-dbalt1)
CONN           Failed to connect to database alt1
CONN           Failover: attempting to connect to database alt2 (-dbalt2)
At logging level 3 or higher, an additional message is logged if the connection set (primary and alternates) is tried again. The number of retries of the connection set, and the pause in between, is controlled by the -retryConnect and -retryConnectPause settings. For example:
CONN           Pausing 3 seconds between connection attempts
At logging level 3 or higher, if the session is restarted due to an unhandled STOP condition, for a GUI or character-mode client, and -autoReconnect is enabled, a message is logged:
CONN           Session restart: attempting to reconnect any disconnected databases
CONN           Successful reconnection ...

Logging for connections to OpenEdge replication-enabled databases

If Automatic database reconnection with OpenEdge replication is enabled, and the logging level is set to 3 or higher, additional messages are logged. The messages are described below in more detail.

When the client initially connects to a database, the AVM determines if the database is enabled for replication:
CONN           Connected to replication-enabled database db0 (source)

or

CONN           Connected to replication-enabled database db1 (target)
When the client receives a database user notification from the replication server, indicating the replication target has changed, a message is logged:
CONN           Refresh replication transition information for database db0
On session restart, the client attempts to reconnect to the database specified at startup. The message could say (replication source) or (replication target).
CONN           Attempting to connect to database db0 (replication source)

If the replication transition is in process, one of two messages is logged, depending on the replication state:

CONN           Replication source database db0 is transitioning, rejecting connection

or

CONN           Database db1 is not a replication source, rejecting connection
A message is logged when attempting to connect to the replication target database, after the connection to the replication source either fails or is rejected:
CONN           Failover: attempting to connect to database db1 (replication target)
A message is logged when the target database has completed the transition and is now the replication source:
CONN           Database db1 has transitioned to a replication source
A message is logged when the connection to the transitioned database is successful:
CONN           Connected to replication-enabled database db1 (source)
CONN           Successful reconnection: -db db0,-H hostname,-S port,-ct 1,-U username,-P