use of org.neo4j.internal.batchimport.BatchImporterFactory in project neo4j by neo4j.
the class StoreUpgraderTest method newUpgrader.
private StoreUpgrader newUpgrader(StoreVersionCheck storeVersionCheck, PageCache pageCache, Config config, MigrationProgressMonitor progressMonitor, PageCacheTracer pageCacheTracer, boolean forceUpgrade) {
NullLogService instance = NullLogService.getInstance();
BatchImporterFactory batchImporterFactory = BatchImporterFactory.withHighestPriority();
RecordStorageMigrator defaultMigrator = new RecordStorageMigrator(fileSystem, pageCache, getTuningConfig(), instance, jobScheduler, pageCacheTracer, batchImporterFactory, INSTANCE);
StorageEngineFactory storageEngineFactory = StorageEngineFactory.defaultStorageEngine();
SchemaIndexMigrator indexMigrator = new SchemaIndexMigrator("Indexes", fileSystem, pageCache, IndexProvider.EMPTY.directoryStructure(), storageEngineFactory, true);
LegacyTransactionLogsLocator logsLocator = new LegacyTransactionLogsLocator(config, databaseLayout);
DatabaseHealth databaseHealth = new DatabaseHealth(NO_OP, NullLog.getInstance());
Dependencies dependencies = new Dependencies();
dependencies.satisfyDependencies(new Monitors());
LogsUpgrader logsUpgrader = new LogsUpgrader(fileSystem, storageEngineFactory, databaseLayout, pageCache, logsLocator, config, dependencies, pageCacheTracer, INSTANCE, databaseHealth, forceUpgrade);
StoreUpgrader upgrader = new StoreUpgrader(storeVersionCheck, progressMonitor, config, fileSystem, NullLogProvider.getInstance(), logsUpgrader, pageCacheTracer);
upgrader.addParticipant(indexMigrator);
upgrader.addParticipant(NOT_PARTICIPATING);
upgrader.addParticipant(NOT_PARTICIPATING);
upgrader.addParticipant(NOT_PARTICIPATING);
upgrader.addParticipant(NOT_PARTICIPATING);
upgrader.addParticipant(defaultMigrator);
return upgrader;
}
use of org.neo4j.internal.batchimport.BatchImporterFactory in project neo4j by neo4j.
the class RecordStorageEngineFactory method migrationParticipants.
@Override
public List<StoreMigrationParticipant> migrationParticipants(FileSystemAbstraction fs, Config config, PageCache pageCache, JobScheduler jobScheduler, LogService logService, PageCacheTracer cacheTracer, MemoryTracker memoryTracker) {
BatchImporterFactory batchImporterFactory = BatchImporterFactory.withHighestPriority();
RecordStorageMigrator recordStorageMigrator = new RecordStorageMigrator(fs, pageCache, config, logService, jobScheduler, cacheTracer, batchImporterFactory, memoryTracker);
IdGeneratorMigrator idGeneratorMigrator = new IdGeneratorMigrator(fs, pageCache, config, cacheTracer);
return List.of(recordStorageMigrator, idGeneratorMigrator);
}
Aggregations