Search in sources :

Example 6 with KernelContext

use of org.neo4j.kernel.impl.spi.KernelContext in project neo4j by neo4j.

the class NeoStoreDataSourceRule method nativeLabelScanStoreProvider.

public static LabelScanStoreProvider nativeLabelScanStoreProvider(File storeDir, FileSystemAbstraction fs, PageCache pageCache, Config config, LogService logService) {
    try {
        Dependencies dependencies = new Dependencies();
        dependencies.satisfyDependencies(pageCache, config, IndexStoreView.EMPTY, logService);
        KernelContext kernelContext = new SimpleKernelContext(storeDir, DatabaseInfo.COMMUNITY, dependencies);
        return (LabelScanStoreProvider) new NativeLabelScanStoreExtension().newInstance(kernelContext, DependenciesProxy.dependencies(dependencies, NativeLabelScanStoreExtension.Dependencies.class));
    } catch (Throwable e) {
        throw launderedException(e);
    }
}
Also used : LabelScanStoreProvider(org.neo4j.kernel.impl.api.scan.LabelScanStoreProvider) SimpleKernelContext(org.neo4j.kernel.impl.spi.SimpleKernelContext) NativeLabelScanStoreExtension(org.neo4j.kernel.impl.api.scan.NativeLabelScanStoreExtension) Dependencies(org.neo4j.kernel.impl.util.Dependencies) SimpleKernelContext(org.neo4j.kernel.impl.spi.SimpleKernelContext) KernelContext(org.neo4j.kernel.impl.spi.KernelContext)

Aggregations

KernelContext (org.neo4j.kernel.impl.spi.KernelContext)6 Dependencies (org.neo4j.kernel.impl.util.Dependencies)5 SimpleKernelContext (org.neo4j.kernel.impl.spi.SimpleKernelContext)4 LifeSupport (org.neo4j.kernel.lifecycle.LifeSupport)4 IOException (java.io.IOException)3 Log (org.neo4j.logging.Log)3 File (java.io.File)2 AccessStatistics (org.neo4j.consistency.statistics.AccessStatistics)2 AccessStatsKeepingStoreAccess (org.neo4j.consistency.statistics.AccessStatsKeepingStoreAccess)2 DefaultCounts (org.neo4j.consistency.statistics.DefaultCounts)2 VerboseStatistics (org.neo4j.consistency.statistics.VerboseStatistics)2 PageCache (org.neo4j.io.pagecache.PageCache)2 DirectStoreAccess (org.neo4j.kernel.api.direct.DirectStoreAccess)2 SchemaIndexProvider (org.neo4j.kernel.api.index.SchemaIndexProvider)2 LabelScanStore (org.neo4j.kernel.api.labelscan.LabelScanStore)2 Config (org.neo4j.kernel.configuration.Config)2 KernelExtensionFactory (org.neo4j.kernel.extension.KernelExtensionFactory)2 KernelExtensions (org.neo4j.kernel.extension.KernelExtensions)2 NamedLabelScanStoreSelectionStrategy (org.neo4j.kernel.extension.dependency.NamedLabelScanStoreSelectionStrategy)2 IndexStoreView (org.neo4j.kernel.impl.api.index.IndexStoreView)2