You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Chetan Mehrotra (JIRA)" <ji...@apache.org> on 2014/03/18 06:52:42 UTC
[jira] [Resolved] (OAK-280) H2 should be configured for not to
close on exit
[ https://issues.apache.org/jira/browse/OAK-280?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Chetan Mehrotra resolved OAK-280.
---------------------------------
Resolution: Won't Fix
H2 based MK is not currently used in OSGi env where this issue is primarily seen.
> H2 should be configured for not to close on exit
> ------------------------------------------------
>
> Key: OAK-280
> URL: https://issues.apache.org/jira/browse/OAK-280
> Project: Jackrabbit Oak
> Issue Type: Improvement
> Components: mk
> Affects Versions: 0.5
> Reporter: Chetan Mehrotra
> Assignee: Chetan Mehrotra
> Priority: Minor
>
> By default H2 registers itself with shutdown hook to close the database on exit. However in managed env like OSGi it would be preferable to disable this behaviour[1] as bundle shutdown logic takes care of closing such resources.
> Without this following exceptions are logged
> {noformat}
> 24.08.2012 19:11:09.005 *ERROR* [RevisionStore-GC] org.apache.jackrabbit.mk.store.DefaultRevisionStore Exception occurred in GC cycle org.h2.jdbc.JdbcSQLException: Database is already closed (to disable automatic closing at VM shutdown, add ";DB_CLOSE_ON_EXIT=FALSE" to the db URL) [90121-158]
> at org.h2.message.DbException.getJdbcSQLException(DbException.java:329)
> at org.h2.message.DbException.get(DbException.java:169)
> at org.h2.message.DbException.get(DbException.java:146)
> at org.h2.message.DbException.get(DbException.java:135)
> at org.h2.jdbc.JdbcConnection.checkClosed(JdbcConnection.java:1394)
> at org.h2.jdbc.JdbcConnection.checkClosedForWrite(JdbcConnection.java:1379)
> at org.h2.jdbc.JdbcConnection.rollback(JdbcConnection.java:463)
> at org.h2.jdbcx.JdbcXAConnection.getConnection(JdbcXAConnection.java:106)
> at org.h2.jdbcx.JdbcConnectionPool.getConnectionNow(JdbcConnectionPool.java:228)
> at org.h2.jdbcx.JdbcConnectionPool.getConnection(JdbcConnectionPool.java:199)
> at org.apache.jackrabbit.mk.persistence.H2Persistence.readCommit(H2Persistence.java:168)
> {noformat}
> [1] http://www.h2database.com/html/features.html#do_not_close_on_exit
--
This message was sent by Atlassian JIRA
(v6.2#6252)