public class FileStoreExpireImpl extends Object implements FileStoreExpire
FileStoreExpire
. It retains a certain number or period of
latest snapshots.
NOTE: This implementation will keep at least one snapshot so that users will not accidentally clear all snapshots.
TODO: add concurrent tests.
Constructor and Description |
---|
FileStoreExpireImpl(int numRetainedMin,
int numRetainedMax,
long millisRetained,
FileStorePathFactory pathFactory,
SnapshotManager snapshotManager,
ManifestFile.Factory manifestFileFactory,
ManifestList.Factory manifestListFactory) |
Modifier and Type | Method and Description |
---|---|
void |
expire()
Expire snapshots.
|
FileStoreExpire |
withLock(Lock lock)
With global lock.
|
public FileStoreExpireImpl(int numRetainedMin, int numRetainedMax, long millisRetained, FileStorePathFactory pathFactory, SnapshotManager snapshotManager, ManifestFile.Factory manifestFileFactory, ManifestList.Factory manifestListFactory)
public FileStoreExpire withLock(Lock lock)
FileStoreExpire
withLock
in interface FileStoreExpire
public void expire()
FileStoreExpire
expire
in interface FileStoreExpire
Copyright © 2019–2023 The Apache Software Foundation. All rights reserved.