jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kadir Alaca <al...@web.de>
Subject In-memory Repository
Date Wed, 16 Sep 2009 22:54:05 GMT
Hi all.

I'm using JR in-memory repository for unit tests
where i create some custom nodes which in turn contain binary images.

Is the correct behavior, that JR should hold its whole data,
inclusively the lucene index, and the created nodes and imported binary 
files in memory?

If so, i have a different behavior than that:
JR generates among others the ./workspaces/default/blobs/ folder which 
contains sub folders with binary images.

After shutting down the repository, these generated sub folders and 
files are removed, thats OK.


How can i configure JR to hold all data in-memory?


Here my current configuration for unit tests:

<Repository>
    <FileSystem class="org.apache.jackrabbit.core.fs.mem.MemoryFileSystem">
    </FileSystem>

    <Security appName="Jackrabbit">
        <SecurityManager 
class="org.apache.jackrabbit.core.security.simple.SimpleSecurityManager" 
workspaceName="security">
        </SecurityManager>

        <AccessManager 
class="org.apache.jackrabbit.core.security.simple.SimpleAccessManager">
        </AccessManager>

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

    <Workspaces rootPath="${rep.home}/workspaces" 
defaultWorkspace="default"/>
    <Workspace name="${wsp.name}">
        <FileSystem 
class="org.apache.jackrabbit.core.fs.mem.MemoryFileSystem">
        </FileSystem>

        <PersistenceManager 
class="org.apache.jackrabbit.core.persistence.mem.InMemPersistenceManager">
            <param name="persistent" value="false"/>
        </PersistenceManager>

        <SearchIndex 
class="org.apache.jackrabbit.core.query.lucene.SearchIndex">
            <param name="directoryManagerClass" 
value="org.apache.jackrabbit.core.query.lucene.directory.RAMDirectoryManager" 
/>
            <param name="path" value="${wsp.home}/index"/>
            <param name="extractorPoolSize" value="2"/>
            <param name="supportHighlighting" value="true"/>
        </SearchIndex>
    </Workspace>

    <Versioning rootPath="${rep.home}/version">
        <FileSystem 
class="org.apache.jackrabbit.core.fs.mem.MemoryFileSystem">
        </FileSystem>

        <PersistenceManager 
class="org.apache.jackrabbit.core.persistence.mem.InMemPersistenceManager">
            <param name="persistent" value="false"/>
        </PersistenceManager>

        <SearchIndex 
class="org.apache.jackrabbit.core.query.lucene.SearchIndex">
            <param name="directoryManagerClass" 
value="org.apache.jackrabbit.core.query.lucene.directory.RAMDirectoryManager" 
/>
            <param name="path" value="${wsp.home}/index"/>
            <param name="extractorPoolSize" value="2"/>
            <param name="supportHighlighting" value="true"/>
        </SearchIndex>
    </Versioning>

    <SearchIndex 
class="org.apache.jackrabbit.core.query.lucene.SearchIndex">
        <param name="directoryManagerClass" 
value="org.apache.jackrabbit.core.query.lucene.directory.RAMDirectoryManager" 
/>
        <param name="path" value="${rep.home}/repository/index"/>
        <param name="extractorPoolSize" value="2"/>
        <param name="supportHighlighting" value="true"/>
    </SearchIndex>
</Repository>


Thanks,
Kadir


Mime
View raw message