public interface OStorage extends OBackupable, OSharedContainer, OStorageInfo
ODirectMemoryStorage
Modifier and Type | Interface and Description |
---|---|
static class |
OStorage.LOCKING_STRATEGY |
static class |
OStorage.STATUS |
Modifier and Type | Field and Description |
---|---|
static String |
CLUSTER_DEFAULT_NAME |
Modifier and Type | Method and Description |
---|---|
int |
addCluster(String iClusterName,
int iRequestedId)
Add a new cluster into the storage.
|
int |
addCluster(String iClusterName,
Object... iParameters)
Add a new cluster into the storage.
|
OPhysicalPosition[] |
ceilingPhysicalPositions(int clusterId,
OPhysicalPosition physicalPosition) |
boolean |
checkForRecordValidity(OPhysicalPosition ppos) |
boolean |
cleanOutRecord(ORecordId recordId,
int recordVersion,
int iMode,
ORecordCallback<Boolean> callback) |
void |
clearProperties() |
void |
close() |
void |
close(boolean iForce,
boolean onDelete) |
Object |
command(OCommandRequestText iCommand)
Execute the command request and return the result back.
|
List<ORecordOperation> |
commit(OTransactionInternal iTx) |
long |
count(int iClusterId) |
long |
count(int[] iClusterIds) |
long |
count(int[] iClusterIds,
boolean countTombstones) |
long |
count(int iClusterId,
boolean countTombstones) |
long |
countRecords()
Returns the total number of records.
|
void |
create(OContextConfiguration contextConfiguration) |
void |
delete() |
OStorageOperationResult<Boolean> |
deleteRecord(ORecordId iRecordId,
int iVersion,
int iMode,
ORecordCallback<Boolean> iCallback) |
boolean |
dropCluster(int iId)
Drops a cluster.
|
boolean |
dropCluster(String iClusterName) |
boolean |
exists() |
OPhysicalPosition[] |
floorPhysicalPositions(int clusterId,
OPhysicalPosition physicalPosition) |
void |
fullIncrementalBackup(OutputStream stream) |
long[] |
getClusterDataRange(int currentClusterId)
Returns a pair of long values telling the begin and end positions of data in the requested
cluster.
|
String |
getClusterEncryption(int clusterId) |
int |
getClusterIdByName(String iClusterName) |
Collection<? extends OCluster> |
getClusterInstances() |
String |
getClusterName(int clusterId) |
String |
getClusterNameById(int clusterId) |
Set<String> |
getClusterNames() |
long |
getClusterNextPosition(int clusterId) |
String |
getClusterRecordConflictStrategy(int clusterId) |
long |
getClusterRecordsSizeById(int clusterId) |
long |
getClusterRecordsSizeByName(String clusterName) |
OCurrentStorageComponentsFactory |
getComponentsFactory() |
String |
getCreatedAtVersion() |
long |
getLastClusterPosition(int clusterId) |
String |
getName() |
String |
getPhysicalClusterNameById(int iClusterId) |
ORecordConflictStrategy |
getRecordConflictStrategy() |
ORecordMetadata |
getRecordMetadata(ORID rid) |
OPaginatedCluster.RECORD_STATUS |
getRecordStatus(ORID rid) |
OSBTreeCollectionManager |
getSBtreeCollectionManager() |
long |
getSize()
Returns the size of the database.
|
OStorage.STATUS |
getStatus()
Returns the current storage's status
|
String |
getType()
Returns the storage's type.
|
OStorage |
getUnderlying() |
long |
getVersion() |
OPhysicalPosition[] |
higherPhysicalPositions(int clusterId,
OPhysicalPosition physicalPosition) |
String |
incrementalBackup(String backupDirectory,
OCallable<Void,Void> started) |
boolean |
isAssigningClusterIds() |
boolean |
isClosed() |
boolean |
isDistributed() |
boolean |
isRemote() |
boolean |
isSystemCluster(int clusterId) |
OPhysicalPosition[] |
lowerPhysicalPositions(int clusterId,
OPhysicalPosition physicalPosition) |
void |
open(String iUserName,
String iUserPassword,
OContextConfiguration contextConfiguration) |
OStorageOperationResult<ORawBuffer> |
readRecord(ORecordId iRid,
String iFetchPlan,
boolean iIgnoreCache,
boolean prefetchRecords,
ORecordCallback<ORawBuffer> iCallback) |
OStorageOperationResult<ORawBuffer> |
readRecordIfVersionIsNotLatest(ORecordId rid,
String fetchPlan,
boolean ignoreCache,
int recordVersion) |
void |
reload() |
void |
removeProperty(String property) |
void |
restoreFromIncrementalBackup(String filePath) |
void |
restoreFullIncrementalBackup(InputStream stream) |
void |
rollback(OTransactionInternal iTx) |
void |
setCharset(String charset) |
boolean |
setClusterAttribute(int id,
OCluster.ATTRIBUTES attribute,
Object value) |
boolean |
setClusterAttribute(String clusterName,
OCluster.ATTRIBUTES attribute,
Object value) |
void |
setClusterSelection(String clusterSelection) |
void |
setConflictStrategy(ORecordConflictStrategy iResolver) |
void |
setDateFormat(String dateFormat) |
void |
setDateTimeFormat(String dateTimeFormat) |
void |
setDefaultClusterId(int defaultClusterId) |
void |
setIndexMgrRecordId(String indexMgrRecordId) |
void |
setLocaleCountry(String localeCountry) |
void |
setLocaleLanguage(String locale) |
void |
setMinimumClusters(int minimumClusters) |
void |
setProperty(String property,
String value) |
void |
setRecordSerializer(String recordSerializer,
int version) |
void |
setSchemaRecordId(String schemaRecordId) |
void |
setTimeZone(TimeZone timeZoneValue) |
void |
setValidation(boolean validation) |
void |
shutdown()
This method is called in
Orient.shutdown() method. |
boolean |
supportIncremental() |
void |
synch() |
backup, restore
existsResource, getResource, removeResource
getClusters, getConfiguration, getDefaultClusterId, getURL
static final String CLUSTER_DEFAULT_NAME
void open(String iUserName, String iUserPassword, OContextConfiguration contextConfiguration)
void create(OContextConfiguration contextConfiguration) throws IOException
IOException
boolean exists()
void reload()
void delete()
void close()
void close(boolean iForce, boolean onDelete)
boolean isClosed()
OStorageOperationResult<ORawBuffer> readRecord(ORecordId iRid, String iFetchPlan, boolean iIgnoreCache, boolean prefetchRecords, ORecordCallback<ORawBuffer> iCallback)
OStorageOperationResult<ORawBuffer> readRecordIfVersionIsNotLatest(ORecordId rid, String fetchPlan, boolean ignoreCache, int recordVersion) throws ORecordNotFoundException
ORecordNotFoundException
OStorageOperationResult<Boolean> deleteRecord(ORecordId iRecordId, int iVersion, int iMode, ORecordCallback<Boolean> iCallback)
ORecordMetadata getRecordMetadata(ORID rid)
boolean cleanOutRecord(ORecordId recordId, int recordVersion, int iMode, ORecordCallback<Boolean> callback)
List<ORecordOperation> commit(OTransactionInternal iTx)
void rollback(OTransactionInternal iTx)
Set<String> getClusterNames()
getClusterNames
in interface OStorageInfo
Collection<? extends OCluster> getClusterInstances()
int addCluster(String iClusterName, Object... iParameters)
iClusterName
- name of the clusterint addCluster(String iClusterName, int iRequestedId)
iClusterName
- name of the clusteriRequestedId
- requested id of the clusterboolean dropCluster(String iClusterName)
String getClusterName(int clusterId)
boolean setClusterAttribute(int id, OCluster.ATTRIBUTES attribute, Object value)
boolean dropCluster(int iId)
iId
- id of the cluster to deleteString getClusterNameById(int clusterId)
long getClusterRecordsSizeById(int clusterId)
long getClusterRecordsSizeByName(String clusterName)
boolean setClusterAttribute(String clusterName, OCluster.ATTRIBUTES attribute, Object value)
String getClusterRecordConflictStrategy(int clusterId)
String getClusterEncryption(int clusterId)
boolean isSystemCluster(int clusterId)
long getLastClusterPosition(int clusterId)
long getClusterNextPosition(int clusterId)
OPaginatedCluster.RECORD_STATUS getRecordStatus(ORID rid)
long count(int iClusterId)
long count(int iClusterId, boolean countTombstones)
long count(int[] iClusterIds)
long count(int[] iClusterIds, boolean countTombstones)
long getSize()
long countRecords()
void setDefaultClusterId(int defaultClusterId)
int getClusterIdByName(String iClusterName)
String getPhysicalClusterNameById(int iClusterId)
boolean checkForRecordValidity(OPhysicalPosition ppos)
String getName()
long getVersion()
String getCreatedAtVersion()
void synch()
Object command(OCommandRequestText iCommand)
long[] getClusterDataRange(int currentClusterId)
currentClusterId
- Cluster idOPhysicalPosition[] higherPhysicalPositions(int clusterId, OPhysicalPosition physicalPosition)
OPhysicalPosition[] lowerPhysicalPositions(int clusterId, OPhysicalPosition physicalPosition)
OPhysicalPosition[] ceilingPhysicalPositions(int clusterId, OPhysicalPosition physicalPosition)
OPhysicalPosition[] floorPhysicalPositions(int clusterId, OPhysicalPosition physicalPosition)
OStorage.STATUS getStatus()
String getType()
OStorage getUnderlying()
boolean isRemote()
boolean isDistributed()
boolean isAssigningClusterIds()
isAssigningClusterIds
in interface OStorageInfo
OSBTreeCollectionManager getSBtreeCollectionManager()
OCurrentStorageComponentsFactory getComponentsFactory()
ORecordConflictStrategy getRecordConflictStrategy()
void setConflictStrategy(ORecordConflictStrategy iResolver)
String incrementalBackup(String backupDirectory, OCallable<Void,Void> started) throws UnsupportedOperationException
UnsupportedOperationException
boolean supportIncremental()
void fullIncrementalBackup(OutputStream stream) throws UnsupportedOperationException
UnsupportedOperationException
void restoreFromIncrementalBackup(String filePath)
void restoreFullIncrementalBackup(InputStream stream) throws UnsupportedOperationException
UnsupportedOperationException
void shutdown()
Orient.shutdown()
method.
For most of the storages it means that storage will be merely closed, but sometimes additional
operations are need to be taken in account.void setSchemaRecordId(String schemaRecordId)
void setDateFormat(String dateFormat)
void setTimeZone(TimeZone timeZoneValue)
void setLocaleLanguage(String locale)
void setCharset(String charset)
void setIndexMgrRecordId(String indexMgrRecordId)
void setDateTimeFormat(String dateTimeFormat)
void setLocaleCountry(String localeCountry)
void setClusterSelection(String clusterSelection)
void setMinimumClusters(int minimumClusters)
void setValidation(boolean validation)
void removeProperty(String property)
void setRecordSerializer(String recordSerializer, int version)
void clearProperties()
Copyright © 2009–2020 OrientDB. All rights reserved.