public abstract class OStorageAbstract extends Object implements OStorage, OSharedContainer
OStorage.LOCKING_STRATEGY, OStorage.STATUS
Modifier and Type | Field and Description |
---|---|
protected OCurrentStorageComponentsFactory |
componentsFactory |
protected OStorageConfiguration |
configuration |
protected String |
mode |
protected String |
name |
protected OSharedContainerImpl |
sharedContainer
This field is used in EE version, do not make it private
|
protected OReadersWriterSpinLock |
stateLock |
protected OStorage.STATUS |
status |
static ThreadGroup |
storageThreadGroup |
protected String |
url |
CLUSTER_DEFAULT_NAME
Constructor and Description |
---|
OStorageAbstract(String name,
String iURL,
String mode) |
Modifier and Type | Method and Description |
---|---|
boolean |
checkForRecordValidity(OPhysicalPosition ppos) |
void |
close() |
void |
close(boolean iForce,
boolean onDelete) |
long |
countRecords()
Returns the total number of records.
|
boolean |
dropCluster(String iClusterName) |
boolean |
existsResource(String iName) |
OCurrentStorageComponentsFactory |
getComponentsFactory() |
OStorageConfiguration |
getConfiguration() |
String |
getName() |
<T> T |
getResource(String iName,
Callable<T> iCallback) |
OStorage.STATUS |
getStatus()
Returns the current storage's status
|
OStorage |
getUnderlying() |
String |
getURL() |
long |
getVersion()
Returns current storage's version as serial.
|
boolean |
isAssigningClusterIds() |
boolean |
isClosed() |
boolean |
isDistributed() |
protected String |
normalizeName(String name) |
<T> T |
removeResource(String iName) |
void |
shutdown()
This method is called in
Orient.shutdown() method. |
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addCluster, addCluster, ceilingPhysicalPositions, cleanOutRecord, clearProperties, command, commit, count, count, count, count, create, delete, deleteRecord, dropCluster, exists, floorPhysicalPositions, fullIncrementalBackup, getClusterDataRange, getClusterEncryption, getClusterIdByName, getClusterInstances, getClusterName, getClusterNameById, getClusterNames, getClusterNextPosition, getClusterRecordConflictStrategy, getClusterRecordsSizeById, getClusterRecordsSizeByName, getCreatedAtVersion, getLastClusterPosition, getPhysicalClusterNameById, getRecordConflictStrategy, getRecordMetadata, getRecordStatus, getSBtreeCollectionManager, getSize, getType, higherPhysicalPositions, incrementalBackup, isRemote, isSystemCluster, lowerPhysicalPositions, open, readRecord, readRecordIfVersionIsNotLatest, reload, removeProperty, restoreFromIncrementalBackup, restoreFullIncrementalBackup, rollback, setCharset, setClusterAttribute, setClusterAttribute, setClusterSelection, setConflictStrategy, setDateFormat, setDateTimeFormat, setDefaultClusterId, setIndexMgrRecordId, setLocaleCountry, setLocaleLanguage, setMinimumClusters, setProperty, setRecordSerializer, setSchemaRecordId, setTimeZone, setValidation, supportIncremental, synch
backup, restore
getClusters, getDefaultClusterId
public static final ThreadGroup storageThreadGroup
protected final String url
protected final String mode
protected final OReadersWriterSpinLock stateLock
protected volatile OStorageConfiguration configuration
protected volatile OCurrentStorageComponentsFactory componentsFactory
protected String name
protected volatile OStorage.STATUS status
protected final OSharedContainerImpl sharedContainer
public OStorage getUnderlying()
getUnderlying
in interface OStorage
public OStorageConfiguration getConfiguration()
getConfiguration
in interface OStorageInfo
public boolean checkForRecordValidity(OPhysicalPosition ppos)
checkForRecordValidity
in interface OStorage
public String getURL()
getURL
in interface OStorageInfo
public boolean existsResource(String iName)
existsResource
in interface OSharedContainer
public <T> T removeResource(String iName)
removeResource
in interface OSharedContainer
public <T> T getResource(String iName, Callable<T> iCallback)
getResource
in interface OSharedContainer
public long getVersion()
getVersion
in interface OStorage
public boolean dropCluster(String iClusterName)
dropCluster
in interface OStorage
public long countRecords()
OStorage
countRecords
in interface OStorage
public OStorage.STATUS getStatus()
OStorage
public boolean isDistributed()
isDistributed
in interface OStorage
public boolean isAssigningClusterIds()
isAssigningClusterIds
in interface OStorage
isAssigningClusterIds
in interface OStorageInfo
public OCurrentStorageComponentsFactory getComponentsFactory()
getComponentsFactory
in interface OStorage
public void shutdown()
OStorage
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.Copyright © 2009–2020 OrientDB. All rights reserved.