I am modifying my BaseOJBConnector class so it will open up a database
upon the Struts startup, using the PlugIn interface in Struts 1.1. I
can do the db.open() just fine, but I don't see any debug in the log
that the DB has opened. I did notice that only until I do something
like query.execute() that I get the debugging below which tells me that
a new connection has been created. I am assuming that until that point
a new connection is not created and placed in the pool. Is there ANY
advantage to me calling db.open() at all if the connection is not
created until the first call to the DB? Meaning does OJB do any
preprocessing with that beyond figuring out that there is an alias in
my datasource.xml file? Does that create a pool? Thanks.
org.apache.ojb.broker.accesslayer.ConnectionFactoryPooledImpl] INFO:
Create new connection
pool:org.apache.ojb.broker.metadata.JdbcConnectionDescriptor@a04d30[
jcd-alias=rex
default-connection=true
dbms=PostgreSQL
jdbc-level=2.0
driver=org.postgresql.Driver
protocol=jdbc
sub-protocol=postgresql
db-alias=//localhost:5432/abc
user=abc
password=*****
eager-release=false
ConnectionPoolDescriptor={whenExhaustedAction=0,
validationQuery=select count(*) from users, maxIdle=-1, maxActive=5,
maxWait=5000, removeAbandoned=false, numTestsPerEvictionRun=10,
testWhileIdle=false, minEvictableIdleTimeMillis=600000,
testOnReturn=false, logAbandoned=false, removeAbandonedTimeout=300,
timeBetweenEvictionRunsMillis=-1, testOnBorrow=true}
batchMode=false
sequenceDescriptor=org.apache.ojb.broker.metadata.SequenceDescriptor@203
a16[
sequenceManagerClass=class
org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl
Properties={grabSize=5}
]
]
R
--
Robert S. Sfeir
Senior Java Engineer
National Institutes of Health
Center for Information Technology
Department of Enterprise Custom Applications
[EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
