Hello Armin,
I'm confused. How does this happen. OJB always use ConnectionFactory#lookupConnection to lookup connections and doesn't differ between transactional and non-transactional connections, thus the validation query is always performed. The only difference is the lifetime of the connection associated with the used PB instance. With tx the connection will be closed (returned to pool) on PersistenceBroker.commitTransaction() or PersistenceBroker.abortTransaction(). Without running tx the connection only be closed (returned to pool) on PB.close() call. http://db.apache.org/ojb/docu/guides/connection.html#When+does+OJB+open%2Fclose+a+connection
You are right i didn't close the broker. I got lazy by the broker per view pattern. But this code was in a scheduler thread and not in an http request so i have to close it after every performed scheduled task. Thank you so much for clearing that out. Cheers, Dennis