jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sascha Theves (JIRA)" <j...@apache.org>
Subject [jira] Commented: (JCR-2163) Exception logged when repository is shut down
Date Mon, 22 Jun 2009 08:02:07 GMT

    [ https://issues.apache.org/jira/browse/JCR-2163?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12722502#action_12722502
] 

Sascha Theves commented on JCR-2163:
------------------------------------

The databse URL is:

jdbc:derby://localhost:1531/mydb;create=true

The derby server is up and running. The configuration worked well without JNDI. We can log
in to the repository and make changes. The exception only occurs when we try to shut down.

We have debugged the shut down mechanism and it seems that JackRabbit want to use a database
connection that was already closed by JackRabbit in the shut down code.

> Exception logged when repository is shut down
> ---------------------------------------------
>
>                 Key: JCR-2163
>                 URL: https://issues.apache.org/jira/browse/JCR-2163
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-core
>    Affects Versions: 1.5.0
>            Reporter: Sascha Theves
>
> It seems we have the same problem as described in JCR-1499 but we are using the 1.5.0
build and there the fix should already be included.
> We got exceptions when we try to shut down JackRabbit with JackrabbitRepository#shutdown()
and using a derby database. We tried it with derby 10.4.2.0 and 10.5.1.1 but got the same
exceptions.
> The exceptions are occuring since we are using JNDI for database access. Here is our
error log:
> 2009-06-19 14:28:24,817 [OSGi Console] WARN  DatabaseFileSystem - execute failed, about
to reconnect...
> 2009-06-19 14:28:24,817 [OSGi Console] WARN  DatabaseFileSystem - execute failed, about
to reconnect...
> 2009-06-19 14:28:34,808 [OSGi Console] ERROR DatabaseFileSystem - failed to re-establish
connection
> java.sql.SQLNonTransientConnectionException: A network protocol error was encountered
and the connection has been terminated: the requested command encountered an unarchitected
and implementation-specific condition for which there was no architected message
> 	at org.apache.derby.client.am.SQLExceptionFactory40.getSQLException(Unknown Source)
> 	at org.apache.derby.client.am.SqlException.getSQLException(Unknown Source)
> 	at org.apache.derby.client.am.Connection.prepareStatement(Unknown Source)
> 	at xxx.jndi.TSDataSource$TSConnection.prepareStatement(TSDataSource.java:516)
> 	at org.apache.jackrabbit.core.fs.db.DatabaseFileSystem.initPreparedStatements(DatabaseFileSystem.java:1291)
> 	at org.apache.jackrabbit.core.fs.db.DatabaseFileSystem.reestablishConnection(DatabaseFileSystem.java:1041)
> 	at org.apache.jackrabbit.core.fs.db.DatabaseFileSystem.executeStmt(DatabaseFileSystem.java:1085)
> 	at org.apache.jackrabbit.core.fs.db.DatabaseFileSystem.exists(DatabaseFileSystem.java:338)
> 	at org.apache.jackrabbit.core.fs.BasedFileSystem.exists(BasedFileSystem.java:121)
> 	at org.apache.jackrabbit.core.fs.FileSystemResource.makeParentDirs(FileSystemResource.java:102)
> 	at org.apache.jackrabbit.core.RepositoryImpl.storeRepProps(RepositoryImpl.java:1303)
> 	at org.apache.jackrabbit.core.RepositoryImpl.doShutdown(RepositoryImpl.java:1176)
> 	at org.apache.jackrabbit.core.RepositoryImpl.shutdown(RepositoryImpl.java:1111)
> 	at org.apache.jackrabbit.core.TransientRepository.stopRepository(TransientRepository.java:271)
> 	at org.apache.jackrabbit.core.TransientRepository.loggedOut(TransientRepository.java:423)
> 	at org.apache.jackrabbit.core.SessionImpl.notifyLoggedOut(SessionImpl.java:600)
> 	at org.apache.jackrabbit.core.SessionImpl.logout(SessionImpl.java:1174)
> 	at org.apache.jackrabbit.core.XASessionImpl.logout(XASessionImpl.java:403)
> 	at xxx.repository.internal.RuleRepositorySession.logout(RuleRepositorySession.java:110)
> 	at xxx.repository.internal.RuleRepositoryManager.logout(RuleRepositoryManager.java:576)
> 	at xxx.repository.internal.RuleRepositoryManager.stopRuleRepository(RuleRepositoryManager.java:530)
> 	at xxx.tearDownRuleRepository(TeamServerApplication.java:554)
> 	at xxx.stop(TeamServerApplication.java:212)
> 	at org.eclipse.equinox.internal.app.EclipseAppHandle.destroySpecific(EclipseAppHandle.java:87)
> 	at org.osgi.service.application.ApplicationHandle.destroy(ApplicationHandle.java:168)
> 	at org.eclipse.equinox.internal.app.EclipseAppContainer.stopAllApps(EclipseAppContainer.java:377)
> 	at org.eclipse.equinox.internal.app.EclipseAppContainer.bundleChanged(EclipseAppContainer.java:365)
> 	at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:1234)
> 	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
> 	at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:141)
> 	at org.eclipse.osgi.framework.internal.core.Framework.publishBundleEventPrivileged(Framework.java:1518)
> 	at org.eclipse.osgi.framework.internal.core.Framework.publishBundleEvent(Framework.java:1469)
> 	at org.eclipse.osgi.framework.internal.core.Framework.shutdown(Framework.java:667)
> 	at org.eclipse.osgi.framework.internal.core.Framework.close(Framework.java:576)
> 	at org.eclipse.osgi.framework.internal.core.OSGi.close(OSGi.java:41)
> 	at org.eclipse.osgi.framework.internal.core.FrameworkCommandProvider._close(FrameworkCommandProvider.java:1154)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at java.lang.reflect.Method.invoke(Method.java:597)
> 	at org.eclipse.osgi.framework.internal.core.FrameworkCommandInterpreter.execute(FrameworkCommandInterpreter.java:150)
> 	at org.eclipse.osgi.framework.internal.core.FrameworkConsole.docommand(FrameworkConsole.java:302)
> 	at org.eclipse.osgi.framework.internal.core.FrameworkConsole.console(FrameworkConsole.java:287)
> 	at org.eclipse.osgi.framework.internal.core.FrameworkConsole.run(FrameworkConsole.java:223)
> 	at java.lang.Thread.run(Thread.java:619)
> Caused by: org.apache.derby.client.am.DisconnectException: A network protocol error was
encountered and the connection has been terminated: the requested command encountered an unarchitected
and implementation-specific condition for which there was no architected message
> 	at org.apache.derby.client.net.NetConnectionReply.parseCMDCHKRM(Unknown Source)
> 	at org.apache.derby.client.net.NetStatementReply.parsePrepareError(Unknown Source)
> 	at org.apache.derby.client.net.NetStatementReply.parsePRPSQLSTTreply(Unknown Source)
> 	at org.apache.derby.client.net.NetStatementReply.readPrepareDescribeOutput(Unknown Source)
> 	at org.apache.derby.client.net.StatementReply.readPrepareDescribeOutput(Unknown Source)
> 	at org.apache.derby.client.net.NetStatement.readPrepareDescribeOutput_(Unknown Source)
> 	at org.apache.derby.client.am.Statement.readPrepareDescribeOutput(Unknown Source)
> 	at org.apache.derby.client.am.PreparedStatement.readPrepareDescribeInputOutput(Unknown
Source)
> 	at org.apache.derby.client.am.PreparedStatement.flowPrepareDescribeInputOutput(Unknown
Source)
> 	at org.apache.derby.client.am.PreparedStatement.prepare(Unknown Source)
> 	at org.apache.derby.client.am.Connection.prepareStatementX(Unknown Source)
> 	... 43 more
> 	
> 	Here is our repository.xml:
> 	
> 	<?xml version="1.0" encoding="ISO-8859-1"?>
> <!DOCTYPE Repository PUBLIC "-//The Apache Software Foundation//DTD Jackrabbit 1.4//EN"
>                             "http://jackrabbit.apache.org/dtd/repository-1.4.dtd">
> <Repository>
>    <FileSystem class="org.apache.jackrabbit.core.fs.db.DerbyFileSystem">
>       <param name="url" value="java:comp/env/jdbc/repository" />
>       <param name="schemaObjectPrefix" value="fs_" />
>       <param name="driver" value="javax.naming.InitialContext" />
>       <param name="schema" value="derby"/>
>    </FileSystem>
>    <Security appName="Jackrabbit">
>       <AccessManager
>          class="xxx.internal.security.RuleRepositoryAccessManager">
>       </AccessManager>
>       <LoginModule
>          class="xxx.internal.security.RuleRepositoryLoginModule">
>       </LoginModule>
>    </Security>
>    <Workspaces rootPath="${rep.home}/workspaces"
>       defaultWorkspace="default" />
>    <Workspace name="${wsp.name}">
>       <FileSystem class="org.apache.jackrabbit.core.fs.db.DerbyFileSystem">
>          <param name="url" value="java:comp/env/jdbc/repository" />
>          <param name="schemaObjectPrefix" value="${wsp.name}_" />
>          <param name="driver" value="javax.naming.InitialContext" />
>          <param name="schema" value="derby"/>
>       </FileSystem>
>       <PersistenceManager
>          class="org.apache.jackrabbit.core.persistence.bundle.DerbyPersistenceManager">
>          <param name="url" value="java:comp/env/jdbc/repository" />
>          <param name="schemaObjectPrefix" value="${wsp.name}_" />
>          <param name="driver" value="javax.naming.InitialContext" />
>          <param name="schema" value="derby"/>
>       </PersistenceManager>
>       <SearchIndex class="org.apache.jackrabbit.core.query.lucene.SearchIndex">
>          <param name="path" value="${wsp.home}/index" />
>          <param name="useCompoundFile" value="true" />
>          <param name="minMergeDocs" value="100" />
>          <param name="volatileIdleTime" value="3" />
>          <param name="maxMergeDocs" value="2147483647" />
>          <param name="mergeFactor" value="10" />
>          <param name="maxFieldLength" value="10000" />
>          <param name="bufferSize" value="10" />
>          <param name="cacheSize" value="1000" />
>          <param name="forceConsistencyCheck" value="false" />
>          <param name="enableConsistencyCheck" value="false" />
>          <param name="autoRepair" value="true" />
>          <param name="analyzer"
>             value="org.apache.lucene.analysis.standard.StandardAnalyzer" />
>          <param name="queryClass" value="org.apache.jackrabbit.core.query.QueryImpl"
/>
>          <param name="respectDocumentOrder" value="true" />
>          <param name="resultFetchSize" value="2147483647" />
>          <param name="extractorPoolSize" value="0" />
>          <param name="extractorTimeout" value="100" />
>          <param name="extractorBackLogSize" value="100" />
>       </SearchIndex>
>       <ISMLocking class="org.apache.jackrabbit.core.state.FineGrainedISMLocking">
>       </ISMLocking>
>    </Workspace>
>    <Versioning rootPath="${rep.home}/version">
>       <FileSystem class="org.apache.jackrabbit.core.fs.db.DerbyFileSystem">
>          <param name="url" value="java:comp/env/jdbc/repository" />
>          <param name="schemaObjectPrefix" value="version_" />
>          <param name="driver" value="javax.naming.InitialContext" />
>          <param name="schema" value="derby"/>
>       </FileSystem>
>       <PersistenceManager
>          class="org.apache.jackrabbit.core.persistence.bundle.DerbyPersistenceManager">
>          <param name="url" value="java:comp/env/jdbc/repository" />
>          <param name="schemaObjectPrefix" value="version_" />
>          <param name="driver" value="javax.naming.InitialContext" />
>          <param name="schema" value="derby"/>
>       </PersistenceManager>
>       <ISMLocking class="org.apache.jackrabbit.core.state.FineGrainedISMLocking">
>       </ISMLocking>
>    </Versioning>
>    <SearchIndex class="org.apache.jackrabbit.core.query.lucene.SearchIndex">
>       <param name="path" value="${rep.home}/repository/index" />
>    </SearchIndex>
> </Repository>
> And our workspace.xml (we have only the default workspace):
> <?xml version="1.0" encoding="UTF-8"?>
> <Workspace name="default">
>       <FileSystem class="org.apache.jackrabbit.core.fs.db.DerbyFileSystem">
>          <param name="url" value="java:comp/env/jdbc/repository"/>
>          <param name="schemaObjectPrefix" value="${wsp.name}_"/>
>          <param name="driver" value="javax.naming.InitialContext"/>
>          <param name="schema" value="derby"/>
>       </FileSystem>
>       <PersistenceManager class="org.apache.jackrabbit.core.persistence.bundle.DerbyPersistenceManager">
>          <param name="url" value="java:comp/env/jdbc/repository"/>
>          <param name="schemaObjectPrefix" value="${wsp.name}_"/>
>          <param name="driver" value="javax.naming.InitialContext"/>
>          <param name="schema" value="derby"/>
>       </PersistenceManager>
>       <SearchIndex class="org.apache.jackrabbit.core.query.lucene.SearchIndex">
>          <param name="path" value="${wsp.home}/index"/>
>          <param name="useCompoundFile" value="true"/>
>          <param name="minMergeDocs" value="100"/>
>          <param name="volatileIdleTime" value="3"/>
>          <param name="maxMergeDocs" value="2147483647"/>
>          <param name="mergeFactor" value="10"/>
>          <param name="maxFieldLength" value="10000"/>
>          <param name="bufferSize" value="10"/>
>          <param name="cacheSize" value="1000"/>
>          <param name="forceConsistencyCheck" value="false"/>
>          <param name="enableConsistencyCheck" value="false"/>
>          <param name="autoRepair" value="true"/>
>          <param name="analyzer" value="org.apache.lucene.analysis.standard.StandardAnalyzer"/>
>          <param name="queryClass" value="org.apache.jackrabbit.core.query.QueryImpl"/>
>          <param name="respectDocumentOrder" value="true"/>
>          <param name="resultFetchSize" value="2147483647"/>
>          <param name="extractorPoolSize" value="0"/>
>          <param name="extractorTimeout" value="100"/>
>          <param name="extractorBackLogSize" value="100"/>
>       </SearchIndex>
>       <ISMLocking class="org.apache.jackrabbit.core.state.FineGrainedISMLocking">
>       </ISMLocking>
>    </Workspace>

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message