Search in sources :

Example 1 with NodeCountsStage

use of org.neo4j.internal.batchimport.NodeCountsStage in project neo4j by neo4j.

the class CountsComputer method populateCountStore.

private void populateCountStore(CountsAccessor.Updater countsUpdater) {
    try (NodeLabelsCache cache = new NodeLabelsCache(numberArrayFactory, nodes.getHighId(), highLabelId, memoryTracker)) {
        Configuration configuration = Configuration.defaultConfiguration(databaseLayout.databaseDirectory());
        // Count nodes
        superviseDynamicExecution(new NodeCountsStage(configuration, cache, nodes, highLabelId, countsUpdater, progressMonitor, pageCacheTracer));
        // Count relationships
        superviseDynamicExecution(new RelationshipCountsStage(configuration, cache, relationships, highLabelId, highRelationshipTypeId, countsUpdater, numberArrayFactory, progressMonitor, pageCacheTracer, memoryTracker));
    }
}
Also used : RelationshipCountsStage(org.neo4j.internal.batchimport.RelationshipCountsStage) Configuration(org.neo4j.internal.batchimport.Configuration) NodeCountsStage(org.neo4j.internal.batchimport.NodeCountsStage) NodeLabelsCache(org.neo4j.internal.batchimport.cache.NodeLabelsCache)

Aggregations

Configuration (org.neo4j.internal.batchimport.Configuration)1 NodeCountsStage (org.neo4j.internal.batchimport.NodeCountsStage)1 RelationshipCountsStage (org.neo4j.internal.batchimport.RelationshipCountsStage)1 NodeLabelsCache (org.neo4j.internal.batchimport.cache.NodeLabelsCache)1