|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.fcrepo.server.Parameterized
org.fcrepo.server.Pluggable
org.fcrepo.server.Module
org.fcrepo.server.storage.lowlevel.akubra.AkubraLowlevelStorageModule
public class AkubraLowlevelStorageModule
Wraps a Spring-configured AkubraLowlevelStore instance as a
Module.
To use this module, edit $FEDORA_HOME/config/akubra-llstore.xml
as appropriate and replace the existing LowlevelStorage
module in fedora.fcfg with the following:
<module role="org.fcrepo.server.storage.lowlevel.ILowlevelStorage" class="org.fcrepo.server.storage.lowlevel.akubra.AkubraLowlevelStorageModule"/>
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.fcrepo.common.Constants |
|---|
Constants.FedoraHome |
| Field Summary |
|---|
| Constructor Summary | |
|---|---|
AkubraLowlevelStorageModule(Map<String,String> moduleParameters,
Server server,
String role)
|
|
| Method Summary | |
|---|---|
long |
addDatastream(String pid,
InputStream content)
Sets the content of a new datastream version. |
void |
addObject(String pid,
InputStream content)
Adds a new object. |
void |
auditDatastream()
Performs a consistency check against the datastream index if such an index exists. |
void |
auditObject()
Performs a consistency check against the object index if such an index exists. |
long |
getDatastreamSize(String dsKey)
Return the size of a datastream in bytes |
Iterator<String> |
listDatastreams()
Lists all stored datastreams in no particular order. |
Iterator<String> |
listObjects()
Lists all stored objects in no particular order. |
void |
postInitModule()
Second stage of Module initialization. |
void |
rebuildDatastream()
Reconstructs the datastream index if such an index exists. |
void |
rebuildObject()
Reconstructs the object index if such an index exists. |
void |
removeDatastream(String pid)
Removes the content of an existing datastream version. |
void |
removeObject(String pid)
Removes an object. |
long |
replaceDatastream(String pid,
InputStream content)
Sets the content of an existing datastream version. |
void |
replaceObject(String pid,
InputStream content)
Replaces an existing object. |
InputStream |
retrieveDatastream(String pid)
Gets the content of an existing datastream version. |
InputStream |
retrieveObject(String pid)
Gets an existing object. |
void |
setImpl(ILowlevelStorage store)
|
void |
setLLStoreImpl(ILowlevelStorage impl)
|
| Methods inherited from class org.fcrepo.server.Module |
|---|
getRole, getServer, initModule, shutdownModule |
| Methods inherited from class org.fcrepo.server.Pluggable |
|---|
getHelp, getOptionalParameters, getParameterHelp, getRequiredModuleRoles, getRequiredParameters |
| Methods inherited from class org.fcrepo.server.Parameterized |
|---|
getParameter, getParameter, getParameter, getParameterList, getParameters, getParameters, parameterNames, setParameter, setParameters, setParameters |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AkubraLowlevelStorageModule(Map<String,String> moduleParameters,
Server server,
String role)
throws ModuleInitializationException
ModuleInitializationException| Method Detail |
|---|
public void setImpl(ILowlevelStorage store)
public void setLLStoreImpl(ILowlevelStorage impl)
public void postInitModule()
throws ModuleInitializationException
Module
postInitModule in class ModuleModuleInitializationException - If initialization values are invalid or initialization fails for
some other reason.
public void addObject(String pid,
InputStream content)
throws LowlevelStorageException
ILowlevelStorage
addObject in interface ILowlevelStoragepid - the pid of the object.content - the serialized object.
LowlevelStorageException - if the object already exists or
cannot be added for any other reason.
public void replaceObject(String pid,
InputStream content)
throws LowlevelStorageException
ILowlevelStorage
replaceObject in interface ILowlevelStoragepid - the pid of the object.content - the serialized object.
LowlevelStorageException - if the object does not already exist
or cannot be replaced for any other reason.
public InputStream retrieveObject(String pid)
throws LowlevelStorageException
ILowlevelStorage
retrieveObject in interface ILowlevelStoragepid - the pid of the object.
LowlevelStorageException - if the object does not exist or
cannot be read for any other reason.
public void removeObject(String pid)
throws LowlevelStorageException
ILowlevelStorage
removeObject in interface ILowlevelStoragepid - the pid of the object.
LowlevelStorageException - if the object does not exist or
cannot be removed for any other reason.
public void rebuildObject()
throws LowlevelStorageException
ILowlevelStorage
rebuildObject in interface ILowlevelStorageLowlevelStorageException - if an error occurs that prevents the
index from being rebuilt.
public void auditObject()
throws LowlevelStorageException
ILowlevelStorage
auditObject in interface ILowlevelStorageLowlevelStorageException - if an error occurs that prevents the
consistency check from taking place.
public long addDatastream(String pid,
InputStream content)
throws LowlevelStorageException
ILowlevelStorage
addDatastream in interface ILowlevelStoragepid - the $pid "+" $dsId "+" $dsVersionId string that uniquely
identifies the datastream version.content - the content.
LowlevelStorageException - if the datastream version already
exists or cannot be added for any other reason.
public long replaceDatastream(String pid,
InputStream content)
throws LowlevelStorageException
ILowlevelStorage
replaceDatastream in interface ILowlevelStoragepid - the $pid "+" $dsId "+" $dsVersionId string that uniquely
identifies the datastream version.content - the content.
LowlevelStorageException - if the datastream version does not
already exist or cannot be replaced for any other reason.
public InputStream retrieveDatastream(String pid)
throws LowlevelStorageException
ILowlevelStorage
retrieveDatastream in interface ILowlevelStoragepid - the $pid "+" $dsId "+" $dsVersionId string that uniquely
identifies the datastream version.
LowlevelStorageException - if the datastream version does not
exist or cannot be read for any other reason.
public void removeDatastream(String pid)
throws LowlevelStorageException
ILowlevelStorage
removeDatastream in interface ILowlevelStoragepid - the $pid "+" $dsId "+" $dsVersionId string that uniquely
identifies the datastream version.
LowlevelStorageException - if the datastream version does not
exist or cannot be removed for any other reason.
public void rebuildDatastream()
throws LowlevelStorageException
ILowlevelStorage
rebuildDatastream in interface ILowlevelStorageLowlevelStorageException - if an error occurs that prevents the
public void auditDatastream()
throws LowlevelStorageException
ILowlevelStorage
auditDatastream in interface ILowlevelStorageLowlevelStorageException - if an error occurs that prevents the
consistency check from taking place.public Iterator<String> listObjects()
IListable
listObjects in interface IListablepublic Iterator<String> listDatastreams()
IListable
listDatastreams in interface IListable
public long getDatastreamSize(String dsKey)
throws LowlevelStorageException
ISizable
getDatastreamSize in interface ISizableLowlevelStorageException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||