Search in sources :

Example 1 with CountsStoreBatchTransactionApplier

use of org.neo4j.kernel.impl.api.CountsStoreBatchTransactionApplier in project neo4j by neo4j.

the class RecordStorageEngine method applier.

/**
     * Creates a {@link BatchTransactionApplierFacade} that is to be used for all transactions
     * in a batch. Each transaction is handled by a {@link TransactionApplierFacade} which wraps the
     * individual {@link TransactionApplier}s returned by the wrapped {@link BatchTransactionApplier}s.
     *
     * After all transactions have been applied the appliers are closed.
     */
protected BatchTransactionApplierFacade applier(TransactionApplicationMode mode) {
    ArrayList<BatchTransactionApplier> appliers = new ArrayList<>();
    // Graph store application. The order of the decorated store appliers is irrelevant
    appliers.add(new NeoStoreBatchTransactionApplier(neoStores, cacheAccess, lockService));
    if (mode.needsHighIdTracking()) {
        appliers.add(new HighIdBatchTransactionApplier(neoStores));
    }
    if (mode.needsCacheInvalidationOnUpdates()) {
        appliers.add(new CacheInvalidationBatchTransactionApplier(neoStores, cacheAccess));
    }
    // Schema index application
    appliers.add(new IndexBatchTransactionApplier(indexingService, labelScanStoreSync, indexUpdatesSync, neoStores.getNodeStore(), new PropertyLoader(neoStores), indexUpdatesConverter, mode));
    // Legacy index application
    appliers.add(new LegacyBatchIndexApplier(indexConfigStore, legacyIndexApplierLookup, legacyIndexTransactionOrdering, mode));
    // Counts store application
    appliers.add(new CountsStoreBatchTransactionApplier(neoStores.getCounts(), mode));
    // Perform the application
    return new BatchTransactionApplierFacade(appliers.toArray(new BatchTransactionApplier[appliers.size()]));
}
Also used : HighIdBatchTransactionApplier(org.neo4j.kernel.impl.transaction.command.HighIdBatchTransactionApplier) ArrayList(java.util.ArrayList) NeoStoreBatchTransactionApplier(org.neo4j.kernel.impl.transaction.command.NeoStoreBatchTransactionApplier) BatchTransactionApplierFacade(org.neo4j.kernel.impl.api.BatchTransactionApplierFacade) PropertyLoader(org.neo4j.kernel.impl.transaction.state.PropertyLoader) CountsStoreBatchTransactionApplier(org.neo4j.kernel.impl.api.CountsStoreBatchTransactionApplier) HighIdBatchTransactionApplier(org.neo4j.kernel.impl.transaction.command.HighIdBatchTransactionApplier) BatchTransactionApplier(org.neo4j.kernel.impl.api.BatchTransactionApplier) IndexBatchTransactionApplier(org.neo4j.kernel.impl.transaction.command.IndexBatchTransactionApplier) CacheInvalidationBatchTransactionApplier(org.neo4j.kernel.impl.transaction.command.CacheInvalidationBatchTransactionApplier) NeoStoreBatchTransactionApplier(org.neo4j.kernel.impl.transaction.command.NeoStoreBatchTransactionApplier) IndexBatchTransactionApplier(org.neo4j.kernel.impl.transaction.command.IndexBatchTransactionApplier) LegacyBatchIndexApplier(org.neo4j.kernel.impl.api.LegacyBatchIndexApplier) CacheInvalidationBatchTransactionApplier(org.neo4j.kernel.impl.transaction.command.CacheInvalidationBatchTransactionApplier) CountsStoreBatchTransactionApplier(org.neo4j.kernel.impl.api.CountsStoreBatchTransactionApplier)

Aggregations

ArrayList (java.util.ArrayList)1 BatchTransactionApplier (org.neo4j.kernel.impl.api.BatchTransactionApplier)1 BatchTransactionApplierFacade (org.neo4j.kernel.impl.api.BatchTransactionApplierFacade)1 CountsStoreBatchTransactionApplier (org.neo4j.kernel.impl.api.CountsStoreBatchTransactionApplier)1 LegacyBatchIndexApplier (org.neo4j.kernel.impl.api.LegacyBatchIndexApplier)1 CacheInvalidationBatchTransactionApplier (org.neo4j.kernel.impl.transaction.command.CacheInvalidationBatchTransactionApplier)1 HighIdBatchTransactionApplier (org.neo4j.kernel.impl.transaction.command.HighIdBatchTransactionApplier)1 IndexBatchTransactionApplier (org.neo4j.kernel.impl.transaction.command.IndexBatchTransactionApplier)1 NeoStoreBatchTransactionApplier (org.neo4j.kernel.impl.transaction.command.NeoStoreBatchTransactionApplier)1 PropertyLoader (org.neo4j.kernel.impl.transaction.state.PropertyLoader)1