jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thomas Müller <thomas.muel...@day.com>
Subject Re: H2 Persistence Manager problem
Date Mon, 19 Oct 2009 15:20:33 GMT
Hi,

I can't reproduce the problem. Everything works for me. I guess you
have an old Jackrabbit jar file somewhere in your classpath. My test
case:

import javax.jcr.*;
import org.apache.jackrabbit.core.TransientRepository;
public class Test {
    public static void main(String... args) throws Exception {
        System.setProperty("log4j.configuration", "file:log4j.xml");
        Repository repository = new TransientRepository();
        Session session = repository.login(new SimpleCredentials("",
"".toCharArray()));
        Node root = session.getRootNode();
        Node n = root.hasNode("test") ? root.getNode("test") :
root.addNode("test");
        n.setProperty("test", "abc");
        session.save();
        session.logout();
    }
}

Jar files:

commons-collections-3.1.jar
commons-io-1.4.jar
concurrent-1.3.4.jar
h2-1.2.121.jar
jackrabbit-api-1.6.0.jar
jackrabbit-core-1.6.0.jar
jackrabbit-jcr-commons-1.6.0.jar
jackrabbit-spi-1.6.0.jar
jackrabbit-spi-commons-1.6.0.jar
jackrabbit-text-extractors-1.6.0.jar
jcr-1.0.jar
log4j-1.2.14.jar
lucene-core-2.4.1.jar
slf4j-api-1.5.3.jar
slf4j-log4j12-1.5.3.jar

repository.xml: the same as your, except i replaced

<!--	<LoginModule
class="com.inubit.ibis.server.repository.IBISLoginModule"/> -->

with

        <LoginModule
class="org.apache.jackrabbit.core.security.simple.SimpleLoginModule">
           <param name="anonymousId" value="anonymous"/>
           <param name="adminId" value="admin"/>
        </LoginModule>

Log output:

19.10.2009 17:13:18 *INFO * RepositoryImpl: Starting repository...
(RepositoryImpl.java, line 261)
19.10.2009 17:13:18 *INFO * LocalFileSystem: LocalFileSystem
initialized at path repository/repository (LocalFileSystem.java, line
166)
19.10.2009 17:13:18 *INFO * NodeTypeRegistry: no custom node type
definitions found (NodeTypeRegistry.java, line 852)
19.10.2009 17:13:18 *INFO * LocalFileSystem: LocalFileSystem
initialized at path repository/version (LocalFileSystem.java, line
166)
19.10.2009 17:13:19 *INFO * ConnectionRecoveryManager: Database: H2 /
1.2.121 (2009-10-11) (ConnectionRecoveryManager.java, line 345)
19.10.2009 17:13:19 *INFO * ConnectionRecoveryManager: Driver: H2 JDBC
Driver / 1.2.121 (2009-10-11) (ConnectionRecoveryManager.java, line
346)
19.10.2009 17:13:19 *INFO * BundleDbPersistenceManager: version:
checking workspace consistency... (BundleDbPersistenceManager.java,
line 805)
19.10.2009 17:13:19 *INFO * BundleDbPersistenceManager: version:
checked 1/1 bundles. (BundleDbPersistenceManager.java, line 958)
19.10.2009 17:13:19 *INFO * RepositoryImpl: initializing workspace
'ibis'... (RepositoryImpl.java, line 1918)
19.10.2009 17:13:19 *INFO * LocalFileSystem: LocalFileSystem
initialized at path repository/workspaces/ibis (LocalFileSystem.java,
line 166)
19.10.2009 17:13:19 *INFO * ConnectionRecoveryManager: Database: H2 /
1.2.121 (2009-10-11) (ConnectionRecoveryManager.java, line 345)
19.10.2009 17:13:19 *INFO * ConnectionRecoveryManager: Driver: H2 JDBC
Driver / 1.2.121 (2009-10-11) (ConnectionRecoveryManager.java, line
346)
19.10.2009 17:13:19 *INFO * BundleDbPersistenceManager: ibis: checking
workspace consistency... (BundleDbPersistenceManager.java, line 805)
19.10.2009 17:13:19 *INFO * BundleDbPersistenceManager: ibis: checked
3/3 bundles. (BundleDbPersistenceManager.java, line 958)
19.10.2009 17:13:19 *INFO * SearchIndex: Index initialized:
repository/repository/index Version: 3 (SearchIndex.java, line 540)
19.10.2009 17:13:19 *INFO * SearchIndex: Index initialized:
repository/workspaces/ibis/index Version: 3 (SearchIndex.java, line
540)
19.10.2009 17:13:19 *INFO * RepositoryImpl: workspace 'ibis'
initialized (RepositoryImpl.java, line 1922)
19.10.2009 17:13:19 *INFO * RepositoryImpl: Repository started
(RepositoryImpl.java, line 366)
19.10.2009 17:13:19 *INFO * TransientRepository: Transient repository
initialized (TransientRepository.java, line 252)
19.10.2009 17:13:19 *INFO * SimpleSecurityManager: init: using
Repository LoginModule configuration for Jackrabbit
(SimpleSecurityManager.java, line 114)
19.10.2009 17:13:19 *INFO * RepositoryImpl: SecurityManager = class
org.apache.jackrabbit.core.security.simple.SimpleSecurityManager
(RepositoryImpl.java, line 441)
19.10.2009 17:13:19 *INFO * TransientRepository: Session opened
(TransientRepository.java, line 327)
19.10.2009 17:13:19 *INFO * TransientRepository: Session closed
(TransientRepository.java, line 422)
19.10.2009 17:13:19 *INFO * RepositoryImpl: Shutting down
repository... (RepositoryImpl.java, line 1093)
19.10.2009 17:13:19 *INFO * IndexMerger: IndexMerger terminated
(IndexMerger.java, line 341)
19.10.2009 17:13:19 *INFO * SearchIndex: Index closed:
repository/repository/index (SearchIndex.java, line 728)
19.10.2009 17:13:19 *INFO * RepositoryImpl: shutting down workspace
'ibis'... (RepositoryImpl.java, line 2068)
19.10.2009 17:13:19 *INFO * ObservationDispatcher: Notification of
EventListeners stopped. (ObservationDispatcher.java, line 106)
19.10.2009 17:13:19 *INFO * IndexMerger: IndexMerger terminated
(IndexMerger.java, line 341)
19.10.2009 17:13:19 *INFO * SearchIndex: Index closed:
repository/workspaces/ibis/index (SearchIndex.java, line 728)
19.10.2009 17:13:19 *INFO * RepositoryImpl: workspace 'ibis' has been
shutdown (RepositoryImpl.java, line 2074)
19.10.2009 17:13:19 *INFO * RepositoryImpl: Repository has been
shutdown (RepositoryImpl.java, line 1185)
19.10.2009 17:13:19 *INFO * TransientRepository: Transient repository
shut down (TransientRepository.java, line 262)

Regards,
Thomas

Mime
View raw message