I'm running 0.9.4 I have code that amounts to something like this.
odmg = OJB.getInstance();
//open database
db = odmg.newDatabase();
db.open(repositoryXml, Database.OPEN_READ_WRITE);
retrieveAll(foo.class)
PersistenceBrokerFactory.releaseAllInstances();
db.close();
public List retrieveAll(Class type)
{
StringBuffer query = new StringBuffer("select o from ");
query.append(type.getName());
return executeQuery( query );
}
public List executeQuery( StringBuffer query )
{
try
{
Database db = odmg.getDatabase(null);
OQLQuery oqlquery = odmg.newOQLQuery();
oqlquery.create(query.toString());
org.odmg.DList result = (org.odmg.DList) oqlquery.execute();
return result;
}
catch (Exception ex)
{
throw new RuntimeException(ex);
}
}
However, when it's done, there appear to be some database connections held
open. Any idea what resource I"m not freeing, or is there a way to tell
"the pool" to let go of everything?
Thanks
David
This message contains information from Equifax Inc. which may be
confidential and privileged. If you are not an intended recipient, please
refrain from any disclosure, copying, distribution or use of this
information and note that such actions are prohibited. If you have
received this transmission in error, please notify by e-mail
[EMAIL PROTECTED]
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>