Announcement Announcement Module
Collapse
No announcement yet.
HSQLDB datasource is not correctly shutdown Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • HSQLDB datasource is not correctly shutdown

    Hi,

    I have some problems with an HSQLDB datasource in in-process mode. My datasource is configured like this :
    Code:
    <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
            <property name="driverClassName"><value>org.hsqldb.jdbcDriver</value></property>
            <property name="username"><value>sa</value></property>
            <property name="url"><value>jdbc&#58;hsqldb&#58;file&#58;C&#58;\dev\pfe\schaman/target/webapp/WEB-INF/db/schamandb</value></property>
        </bean>
    But apparently the "destroy-method="close" is not enough since when I stop my web application, the HSQLDB lock file is left behind and I can't access my database anymore (without rebooting my computer :roll: ).

    I read on HSQLDB forums that it was because the SHUTDOWN SQL method had to be called so that the lock file can be released, but my question is, how can I integrate that in my Spring configuration ?

    Thx in advance.[/code]

  • #2
    Sorry to awake this very old thread, but google sent me on this page.

    I have exactly the same problem. Do you know where to set the Shutdown statement. I tried to execute this after the transaction but after the getJdbcTemplate does not success to open the connection.

    ( error details: connection exception: closed; nested exception is java.sql.SQLException: connection exception: closed)

    Thanks you if someone can help or give me a more recent link (if existing)

    BR
    Patrick

    Comment

    Working...
    X