use of org.apache.ignite.internal.processors.cache.persistence.file.FilePageStoreManager.PART_FILE_TEMPLATE in project ignite by apache.
the class PagesPossibleCorruptionDiagnosticTest method filePageStore.
/**
* @param ignite Ignite instance.
* @param partId Partition id.
* @return File page store for given partition id.
* @throws IgniteCheckedException If failed.
*/
private FilePageStore filePageStore(IgniteEx ignite, int partId) throws IgniteCheckedException {
final PdsFolderSettings folderSettings = ignite.context().pdsFolderResolver().resolveFolders();
File storeWorkDir = new File(folderSettings.persistentStoreRootPath(), folderSettings.folderName());
File cacheWorkDir = new File(storeWorkDir, CACHE_DIR_PREFIX + DEFAULT_CACHE_NAME);
File partFile = new File(cacheWorkDir, format(PART_FILE_TEMPLATE, partId));
return (FilePageStore) storeFactory.createPageStore(FLAG_DATA, partFile, a -> {
});
}
Aggregations