Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

File system Backends


LevelDB

Info

Specifying fcrepo.ispn.repo.CacheDirPath=/tmp/FedoraRepostiroy would result in a directory with LevelDB artifcats, such as files 000003.log.

Currently, the default configuration outputs Fedora data to LevelDB (a fast filesystem based key-value store). When Fedora 4 is started, Modeshape (actually Infinispan and LevelDB in the background) will create several directories on the filesystem. Currently, the directories created are:

  1. fcrepo.ispn.binary.CacheDirPath (binary data)
  2. fcrepo.ispn.CacheDirPath (metadata)
  3. fcrepo.ispn.repo.CacheDirPath (repository)
  4. fcrepo.modeshape.index.location

The layout of files in directories 1-3 is determined by LevelDB. Some of the important files are:

  1. File .log holds entries for recent transactions. The relevant API for representing these entries is modeshape-schematics (see, e.g., org.infinispan.schematic.SchematicEntry)
  2. File .sst stores these entries when the .log file reaches a size threshold. A new log file is generated.
  3. File MANIFEST.x records info about .sst files (among other things). 
  4. File CURRENT specifies the current MANIFEST file.

Most of these files are binary and can be read by a LevelDB Java library.

FileCacheStore

Info
Specifying fcrepo.ispn.repo.CacheDirPath=/tmp/FedoraRepostiroy would result in creating hundreds of binary files in that directory (e.g. 11333332.. , -2334002.. etc).

Using the Infinispan 6.x deprecated FileCacheStore (specified via file/infinispan.xml, currently our Modeshape is on 5.x) results in creation of hundreds of binary files (compared to LevelDB). A hashing algorithm is used to map keys to buckets. The value files contain serialized Modeshape objects. The key files can be read using org.infinispan.schematic.internal.document.BsonReader. (It does not seem possible to read these files using existing bson tools, like mongoDB bsondump, but further inspection is needed.)