
public class ODirectMemoryStorage extends OAbstractPaginatedStorage
OStorage.LOCKING_STRATEGY, OStorage.SIZE, OStorage.STATUSatomicOperationsManager, readCache, sbTreeCollectionManager, writeAheadLog, writeCachecomponentsFactory, configuration, mode, name, sharedContainer, stateLock, status, storageThreadGroup, url, versionCLUSTER_DEFAULT_NAME| Constructor and Description |
|---|
ODirectMemoryStorage(String name,
String filePath,
String mode,
int id) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addFileToDirectory(String name,
InputStream stream,
File directory) |
List<String> |
backup(OutputStream out,
Map<String,Object> options,
Callable<Object> callable,
OCommandOutputListener iListener,
int compressionLevel,
int bufferSize)
Executes a backup of the database.
|
protected OLogSequenceNumber |
copyWALToIncrementalBackup(ZipOutputStream zipOutputStream,
long startSegment) |
protected OWriteAheadLog |
createWalFromIBUFiles(File directory) |
protected File |
createWalTempDirectory() |
boolean |
exists() |
String |
getType()
Returns the storage's type.
|
String |
getURL() |
protected void |
initWalAndDiskCache() |
protected boolean |
isWriteAllowedDuringIncrementalBackup() |
void |
makeFullCheckpoint() |
protected void |
postCloseSteps(boolean onDelete,
boolean jvmError) |
void |
reload() |
void |
restore(InputStream in,
Map<String,Object> options,
Callable<Object> callable,
OCommandOutputListener iListener)
Executes a restore of a database backup.
|
void |
shutdown()
This method is called in
Orient.shutdown() method. |
acquireReadLock, acquireWriteLock, addCluster, addCluster, addIndexEngine, callIndexEngine, callInLock, cancelIndexRebuild, ceilingPhysicalPositions, check, checkClustersConsistency, checkForRecordValidity, checkOpeness, cleanOutRecord, clearIndex, clearProperties, clearStorageDirty, close, closeClusters, closeIndexes, command, commit, compactCluster, completeGatheringPerformanceStatisticForCurrentThread, count, count, count, count, create, createRecord, delete, deleteIndexEngine, deleteRecord, dropCluster, executeCommand, floorPhysicalPositions, freeze, getAtomicOperationsManager, getClusterById, getClusterByName, getClusterDataRange, getClusterIdByName, getClusterInstances, getClusterNames, getClusters, getConflictStrategy, getDefaultClusterId, getFullCheckpointCount, getId, getIndexCursor, getIndexDescCursor, getIndexEngine, getIndexFirstKey, getIndexKeyCursor, getIndexLastKey, getIndexSize, getIndexValue, getLSN, getMode, getPerformanceStatisticManager, getPhysicalClusterNameById, getReadCache, getRecordMetadata, getRecordScanned, getRecoverListener, getRidsGroupedByCluster, getSBtreeCollectionManager, getSize, getStorageTransaction, getWALInstance, getWriteCache, hasIndexRangeQuerySupport, hideRecord, higherPhysicalPositions, incrementalBackup, indexContainsKey, isClosed, isDirty, isFrozen, isIndexRebuildScheduled, isIndexRebuildScheduledInternal, isRemote, iterateIndexEntriesBetween, iterateIndexEntriesMajor, iterateIndexEntriesMinor, loadExternalIndexEngine, loadIndexEngine, logAndPrepareForRethrow, logAndPrepareForRethrow, logAndPrepareForRethrow, lowDiskSpace, lowerPhysicalPositions, makeStorageDirty, onException, onShutdown, onStartup, open, open, openClusters, openIndexes, pageIsBroken, postCreateSteps, postDeleteSteps, preCloseSteps, preCreateSteps, preOpenSteps, putIndexValue, readRecord, readRecordIfVersionIsNotLatest, readRecords, recordsChangedAfterLSN, recordsChangedRecently, recyclePosition, registerRecoverListener, release, releaseReadLock, releaseWriteLock, removeKeyFromIndex, removeProperty, renameCluster, requestCheckpoint, restoreAtomicUnit, restoreFrom, restoreFromIncrementalBackup, rollback, scheduleIndexRebuild, setCharset, setClusterSelection, setClusterStatus, setConflictStrategy, setDateFormat, setDateTimeFormat, setDefaultClusterId, setIndexMgrRecordId, setLocaleCountry, setLocaleLanguage, setMinimumClusters, setProperty, setRecordSerializer, setSchemaRecordId, setTimeZone, setValidation, startGatheringPerformanceStatisticForCurrentThread, synch, underDistributedStorage, unregisterRecoverListener, updateConfiguration, updateIndexEntry, updateRecord, validatedPutIndexValuecheckForClusterPermissions, close, countRecords, dropCluster, existsResource, getComponentsFactory, getConfiguration, getName, getResource, getStatus, getUnderlying, getVersion, isAssigningClusterIds, isDistributed, normalizeName, removeResource, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitcheckForClusterPermissions, close, countRecords, dropCluster, getComponentsFactory, getConfiguration, getName, getStatus, getUnderlying, getVersion, isAssigningClusterIds, isDistributedexistsResource, getResource, removeResourceprotected void initWalAndDiskCache()
throws IOException
initWalAndDiskCache in class OAbstractPaginatedStorageIOExceptionpublic boolean exists()
public String getType()
OStoragepublic String getURL()
getURL in interface OStoragegetURL in class OStorageAbstractpublic void makeFullCheckpoint()
throws IOException
makeFullCheckpoint in class OAbstractPaginatedStorageIOExceptionpublic List<String> backup(OutputStream out, Map<String,Object> options, Callable<Object> callable, OCommandOutputListener iListener, int compressionLevel, int bufferSize) throws IOException
OBackupableout - OutputStream used to write the backup content. Use a FileOutputStream to make the backup persistent on diskoptions - Backup options as Mapcallable - Callback to execute when the database is lockediListener - Listener called for backup messagescompressionLevel - ZIP Compression level between 1 (the minimum) and 9 (maximum). The bigger is the compression, the smaller will be the
final backup content, but will consume more CPU and time to executebufferSize - Buffer size in bytes, the bigger is the buffer, the more efficient will be the compressionIOExceptionODatabaseExportpublic void restore(InputStream in, Map<String,Object> options, Callable<Object> callable, OCommandOutputListener iListener) throws IOException
OBackupablein - InputStream used to read the backup content. Use a FileInputStream to read a backup on a diskoptions - Backup options as Mapcallable - Callback to execute when the database is lockediListener - Listener called for backup messagesIOExceptionODatabaseImportprotected OLogSequenceNumber copyWALToIncrementalBackup(ZipOutputStream zipOutputStream, long startSegment) throws IOException
copyWALToIncrementalBackup in class OAbstractPaginatedStorageIOExceptionpublic void reload()
reload in interface OStoragereload in class OAbstractPaginatedStorageprotected boolean isWriteAllowedDuringIncrementalBackup()
isWriteAllowedDuringIncrementalBackup in class OAbstractPaginatedStorageprotected File createWalTempDirectory()
createWalTempDirectory in class OAbstractPaginatedStorageprotected void addFileToDirectory(String name, InputStream stream, File directory) throws IOException
addFileToDirectory in class OAbstractPaginatedStorageIOExceptionprotected void postCloseSteps(boolean onDelete,
boolean jvmError)
throws IOException
postCloseSteps in class OAbstractPaginatedStorageIOExceptionprotected OWriteAheadLog createWalFromIBUFiles(File directory) throws IOException
createWalFromIBUFiles in class OAbstractPaginatedStorageIOExceptionpublic void shutdown()
OStorageOrient.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.shutdown in interface OStorageshutdown in class OStorageAbstractCopyright © 2009–2025 OrientDB. All rights reserved.