HI,
We are experiencing a strange behaviour of the HSQL datasource. Our application, jBoss 3.2.1 with embedded jetty, runs on RedHat kernel 2.4.9. After a day run in a production equal environment or after 2-3 hours of stress test the thread dump reveals about 1700 open threads, and the app slows down to halt. There are about 1500 threads, running in org.hsqldb.Log, as the following shows:
"Thread-1562" prio=1 tid=0x93a66610 nid=0x4b35 waiting on condition [94503000..945038c8] at java.lang.Thread.sleep(Native Method) at org.hsqldb.Log.run(Unknown Source) at java.lang.Thread.run(Thread.java:534)
<datasources> <local-tx-datasource> <jndi-name>DefaultDS</jndi-name> <connection-url>jdbc:hsqldb:default-db-name</connection-url> <driver-class>org.hsqldb.jdbcDriver</driver-class> <min-pool-size>5</min-pool-size> <security-domain>HsqlDbRealm</security-domain> </local-tx-datasource> </datasources>
public void run() { while(tRunner!=null) { try { tRunner.sleep(1000); if(bNeedFlush) { wScript.flush(); bNeedFlush=false; } // todo: try to do Cache.cleanUp() here, too } catch(Exception e) { // ignore exceptions; may be InterruptedException or IOException } } }