* - allowStale : Don't require the latest available data.
* This can increase performance for non-critical writes.
* This has no effect unless the 'force' flag is set.
+ * - preserveCache : Don't clear the process cache before checking files.
+ * This should only be used if all entries in the process
+ * cache were added after the files were already locked.
* - nonJournaled : Don't log this operation batch in the file journal.
* This limits the ability of recovery scripts.
* - parallelize : Try to do operations in parallel when possible.
}
// Clear any cache entries (after locks acquired)
$this->clearCache();
+ $opts['preserveCache'] = true; // only locked files are cached
// Do a consistency check to see if the backends agree
$status->merge( $this->consistencyCheck( $this->fileStoragePathsForOps( $ops ) ) );
if ( !$status->isOK() ) {
}
// Clear any file cache entries (after locks acquired)
- $this->clearCache();
+ if ( empty( $opts['preserveCache'] ) ) {
+ $this->clearCache();
+ }
// Load from the persistent file and container caches
$this->primeFileCache( $performOps );