|Datasource State||!= Running||!= Running|
The table above is my template for datasource monitoring in the weblogic server. I have applied it to a target but it sends notificationswhen the status IS RUNNING. The comparison above is "not equal to" but I think it is inaccurate? Could someone explain to me the meaning of ' != ' ?
The "RUNNING" state of datasource implies that datasource health is okay, which inturn means that it is deployed successfully and applications can request for connections. Datasource state "RUNNING" does not necessarily reflect that corresponding DB server is up and accessible to WebLogic.
The cause of the behavior is that Connection Pool's connection retry seconds is set to non-zero value. This deploys the datasource successfully even if connection creation fails at server startup. Weblogic will keep on trying to create new connection as per connection retry seconds. When the pool does connect, it will make it's initial capacity at that time. After a pool has ever connected to the DB server, the connect retry seconds setting has no further affect.
If connection retry is set to zero, the pool will fail to deploy if connection creation fails at server startup. Now, in this case even if DB server comes up, the pool will not be deployed/RUNNING until WebLogic is restarted.
This behavior is in contrast to DB server failure while WebLogic is running. At runtime, (after a pool has ever successfully connected to the DB server), if a pool fails in two successive attempts to make a new connection to replace a failed connection, then the pool will disable itself. When that happens, the pool will try to reconnect/re-enable itself every 5 seconds. This number is not configurable.
Datasource state shows as RUNNING even if corresponding Database server is down (Doc ID 1307696.1)