
public class OLocalPaginatedStorage extends OAbstractPaginatedStorage implements OFreezableStorageComponent
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 |
|---|
OLocalPaginatedStorage(String name,
String filePath,
String mode,
int id,
OReadCache readCache,
OClosableLinkedContainer<Long,OFileClassic> files) |
| 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 iOutput,
int compressionLevel,
int bufferSize)
Executes a backup of the database.
|
void |
cancelIndexRebuild() |
protected void |
clearStorageDirty() |
void |
closeAndMove(OCallable<Void,String> mover) |
protected OLogSequenceNumber |
copyWALToIncrementalBackup(ZipOutputStream zipOutputStream,
long startSegment) |
void |
create(Map<String,Object> iProperties) |
protected OWriteAheadLog |
createWalFromIBUFiles(File directory) |
protected File |
createWalTempDirectory() |
boolean |
exists() |
static boolean |
exists(String path) |
String |
getStoragePath() |
String |
getType()
Returns the storage's type.
|
String |
getURL() |
OStorageVariableParser |
getVariableParser() |
protected void |
initWalAndDiskCache() |
protected boolean |
isDirty() |
boolean |
isIndexRebuildScheduled() |
protected boolean |
isIndexRebuildScheduledInternal() |
protected boolean |
isWriteAllowedDuringIncrementalBackup() |
protected void |
makeStorageDirty() |
protected String |
normalizeName(String name) |
protected void |
postCloseSteps(boolean onDelete,
boolean jvmError) |
protected void |
postDeleteSteps() |
protected void |
preCloseSteps() |
protected void |
preCreateSteps() |
protected void |
preOpenSteps() |
void |
restore(InputStream in,
Map<String,Object> options,
Callable<Object> callable,
OCommandOutputListener iListener)
Executes a restore of a database backup.
|
protected void |
scheduleIndexRebuild() |
acquireReadLock, acquireWriteLock, addCluster, addCluster, addIndexEngine, callIndexEngine, callInLock, ceilingPhysicalPositions, check, checkClustersConsistency, checkForRecordValidity, checkOpeness, cleanOutRecord, clearIndex, clearProperties, close, closeClusters, closeIndexes, command, commit, compactCluster, completeGatheringPerformanceStatisticForCurrentThread, count, count, count, count, 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, isFrozen, isRemote, iterateIndexEntriesBetween, iterateIndexEntriesMajor, iterateIndexEntriesMinor, loadExternalIndexEngine, loadIndexEngine, logAndPrepareForRethrow, logAndPrepareForRethrow, logAndPrepareForRethrow, lowDiskSpace, lowerPhysicalPositions, makeFullCheckpoint, onException, onShutdown, onStartup, open, open, openClusters, openIndexes, pageIsBroken, postCreateSteps, putIndexValue, readRecord, readRecordIfVersionIsNotLatest, readRecords, recordsChangedAfterLSN, recordsChangedRecently, recyclePosition, registerRecoverListener, release, releaseReadLock, releaseWriteLock, reload, removeKeyFromIndex, removeProperty, renameCluster, requestCheckpoint, restoreAtomicUnit, restoreFrom, restoreFromIncrementalBackup, rollback, 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, removeResource, shutdown, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitfreeze, isFrozen, releasecheckForClusterPermissions, close, countRecords, dropCluster, getComponentsFactory, getConfiguration, getName, getStatus, getUnderlying, getVersion, isAssigningClusterIds, isDistributed, shutdownexistsResource, getResource, removeResourcepublic OLocalPaginatedStorage(String name, String filePath, String mode, int id, OReadCache readCache, OClosableLinkedContainer<Long,OFileClassic> files) throws IOException
IOExceptionpublic void create(Map<String,Object> iProperties)
create in interface OStoragecreate in class OAbstractPaginatedStorageprotected String normalizeName(String name)
normalizeName in class OStorageAbstractpublic String getURL()
getURL in interface OStoragegetURL in class OStorageAbstractpublic String getStoragePath()
public OStorageVariableParser getVariableParser()
public String getType()
OStoragepublic List<String> backup(OutputStream out, Map<String,Object> options, Callable<Object> callable, OCommandOutputListener iOutput, int compressionLevel, int bufferSize) throws IOException
OBackupablebackup in interface 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 lockediOutput - 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
OBackupablerestore in interface 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 OAbstractPaginatedStorageIOExceptionprotected File createWalTempDirectory()
createWalTempDirectory in class OAbstractPaginatedStorageprotected void addFileToDirectory(String name, InputStream stream, File directory) throws IOException
addFileToDirectory in class OAbstractPaginatedStorageIOExceptionprotected OWriteAheadLog createWalFromIBUFiles(File directory) throws IOException
createWalFromIBUFiles in class OAbstractPaginatedStorageIOExceptionprotected void preOpenSteps()
throws IOException
preOpenSteps in class OAbstractPaginatedStorageIOExceptionprotected void preCreateSteps()
throws IOException
preCreateSteps in class OAbstractPaginatedStorageIOExceptionprotected void postCloseSteps(boolean onDelete,
boolean jvmError)
throws IOException
postCloseSteps in class OAbstractPaginatedStorageIOExceptionprotected void preCloseSteps()
throws IOException
preCloseSteps in class OAbstractPaginatedStorageIOExceptionprotected void postDeleteSteps()
postDeleteSteps in class OAbstractPaginatedStorageprotected void makeStorageDirty()
throws IOException
makeStorageDirty in class OAbstractPaginatedStorageIOExceptionprotected void clearStorageDirty()
throws IOException
clearStorageDirty in class OAbstractPaginatedStorageIOExceptionprotected boolean isDirty()
throws IOException
isDirty in class OAbstractPaginatedStorageIOExceptionpublic boolean isIndexRebuildScheduled()
isIndexRebuildScheduled in class OAbstractPaginatedStorageprotected boolean isIndexRebuildScheduledInternal()
isIndexRebuildScheduledInternal in class OAbstractPaginatedStorageprotected void scheduleIndexRebuild()
throws IOException
scheduleIndexRebuild in class OAbstractPaginatedStorageIOExceptionpublic void cancelIndexRebuild()
throws IOException
cancelIndexRebuild in class OAbstractPaginatedStorageIOExceptionprotected boolean isWriteAllowedDuringIncrementalBackup()
isWriteAllowedDuringIncrementalBackup in class OAbstractPaginatedStorageprotected void initWalAndDiskCache()
throws IOException
initWalAndDiskCache in class OAbstractPaginatedStorageIOExceptionpublic static boolean exists(String path)
Copyright © 2009–2025 OrientDB. All rights reserved.