I am migrating to Neo4j 5.5.0. I have added the following dependencies to my gradle project.
testImplementation(group: 'org.neo4j.test', name: 'neo4j-harness', version: "$neo4j_Version")
testImplementation group: 'org.apache.groovy', name: 'groovy-json', version: "$groovyVersion"
testImplementation group: 'org.neo4j.gds', name: 'proc-centrality', version: "$neo4jGdsVersion"
testImplementation group: 'org.neo4j.gds', name: 'proc-community', version: "$neo4jGdsVersion"
testImplementation group: 'org.neo4j.gds', name: 'core-write', version: "$neo4jGdsVersion"
testImplementation group: 'org.neo4j.gds', name: 'proc-catalog', version: "$neo4jGdsVersion"
testImplementation group: 'org.neo4j.gds', name: 'proc-common', version: "$neo4jGdsVersion"
testImplementation group: 'org.neo4j.gds', name: 'neo4j-kernel-adapter-api', version: "$neo4jGdsVersion"
testImplementation group: 'org.neo4j.gds', name: 'model-catalog-api', version: "$neo4jGdsVersion"
testImplementation group: 'org.neo4j.gds', name: 'open-model-catalog', version: "$neo4jGdsVersion"
Here neo4j_Version is 5.5.0
neo4jGdsVersion is 2.4.0
While trying to run the tests, I am getting the following error during initialization:
java.lang.ExceptionInInitializerError
at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized(Unsafe.java:1155)
at com.mymodule.MyTestConfig$Initializer.initialize(MyTestConfig.groovy:189)
at org.springframework.test.context.support.AbstractContextLoader.invokeApplicationContextInitializers(AbstractContextLoader.java:172)
at org.springframework.test.context.support.AbstractContextLoader.prepareContext(AbstractContextLoader.java:140)
at org.springframework.test.context.support.AbstractGenericContextLoader.loadContext(AbstractGenericContextLoader.java:213)
at org.springframework.test.context.support.AbstractGenericContextLoader.loadContext(AbstractGenericContextLoader.java:110)
at org.springframework.test.context.support.AbstractDelegatingSmartContextLoader.loadContext(AbstractDelegatingSmartContextLoader.java:212)
at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContextInternal(DefaultCacheAwareContextLoaderDelegate.java:187)
at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:119)
at org.springframework.test.context.support.DefaultTestContext.getApplicationContext(DefaultTestContext.java:127)
at org.springframework.test.context.support.DependencyInjectionTestExecutionListener.injectDependencies(DependencyInjectionTestExecutionListener.java:141)
at org.springframework.test.context.support.DependencyInjectionTestExecutionListener.prepareTestInstance(DependencyInjectionTestExecutionListener.java:97)
at org.springframework.test.context.TestContextManager.prepareTestInstance(TestContextManager.java:241)
at org.spockframework.spring.SpringTestContextManager.prepareTestInstance(SpringTestContextManager.java:56)
at org.spockframework.spring.SpringInterceptor.interceptInitializerMethod(SpringInterceptor.java:46)
at org.spockframework.runtime.extension.AbstractMethodInterceptor.intercept(AbstractMethodInterceptor.java:24)
at org.spockframework.runtime.extension.MethodInvocation.proceed(MethodInvocation.java:101)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$prepare$2(NodeTestTask.java:123)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.prepare(NodeTestTask.java:123)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:90)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
at org.spockframework.runtime.model.MethodInfo.invoke(MethodInfo.java:156)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.submit(SameThreadHierarchicalTestExecutorService.java:35)
at org.junit.platform.engine.support.hierarchical.HierarchicalTestExecutor.execute(HierarchicalTestExecutor.java:57)
at org.junit.platform.engine.support.hierarchical.HierarchicalTestEngine.execute(HierarchicalTestEngine.java:54)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:108)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:88)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:54)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:67)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:52)
at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:96)
at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:75)
at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.processAllTestClasses(JUnitPlatformTestClassProcessor.java:99)
at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.access$000(JUnitPlatformTestClassProcessor.java:79)
at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor.stop(JUnitPlatformTestClassProcessor.java:75)
at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.stop(SuiteTestClassProcessor.java:61)
at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:36)
at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
at org.gradle.internal.dispatch.ContextClassLoaderDispatch.dispatch(ContextClassLoaderDispatch.java:33)
at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:94)
at org.gradle.api.internal.tasks.testing.worker.TestWorker$3.run(TestWorker.java:193)
at org.gradle.api.internal.tasks.testing.worker.TestWorker.executeAndMaintainThreadName(TestWorker.java:129)
at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:100)
at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:60)
at org.gradle.process.internal.worker.child.ActionExecutionWorker.execute(ActionExecutionWorker.java:56)
at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:133)
at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:71)
at worker.org.gradle.process.internal.worker.GradleWorkerMain.run(GradleWorkerMain.java:69)
at worker.org.gradle.process.internal.worker.GradleWorkerMain.main(GradleWorkerMain.java:74)
Caused by: java.lang.RuntimeException: Error starting Neo4j database server at /tmp/0939e2fd0a5e404dc1e5820b0396fc7d/data/databases
at org.neo4j.graphdb.facade.DatabaseManagementServiceFactory.startDatabaseServer(DatabaseManagementServiceFactory.java:256)
at org.neo4j.graphdb.facade.DatabaseManagementServiceFactory.build(DatabaseManagementServiceFactory.java:194)
at org.neo4j.harness.internal.InProcessNeo4jBuilder.createNeo(InProcessNeo4jBuilder.java:45)
at org.neo4j.harness.internal.AbstractInProcessNeo4jBuilder.build(AbstractInProcessNeo4jBuilder.java:136)
at org.neo4j.harness.internal.AbstractInProcessNeo4jBuilder.build(AbstractInProcessNeo4jBuilder.java:67)
at com.mymodule.MyTestConfig.<clinit>(MyTestConfig.groovy:115)
... 68 more
Caused by: org.neo4j.kernel.lifecycle.LifecycleException: Component 'org.neo4j.harness.internal.AbstractInProcessNeo4jBuilder$Neo4jHarnessExtensions$1@3fecb076' was successfully initialized, but failed to start. Please see the attached cause exception "Unable to set up injection for procedure `WccWriteProc`, the field `nodePropertyExporterBuilder` has type `class org.neo4j.gds.core.write.NodePropertyExporterBuilder` which is not a known injectable component.".
at app//org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:370)
at app//org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:92)
at app//org.neo4j.kernel.extension.AbstractExtensions.start(AbstractExtensions.java:78)
at app//org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:353)
at app//org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:92)
at app//org.neo4j.graphdb.facade.DatabaseManagementServiceFactory.startDatabaseServer(DatabaseManagementServiceFactory.java:247)
... 73 more
Caused by: org.neo4j.kernel.api.exceptions.ComponentInjectionException: Unable to set up injection for procedure `WccWriteProc`, the field `nodePropertyExporterBuilder` has type `class org.neo4j.gds.core.write.NodePropertyExporterBuilder` which is not a known injectable component.
at app//org.neo4j.procedure.impl.FieldInjections.createInjector(FieldInjections.java:92)
at app//org.neo4j.procedure.impl.FieldInjections.setters(FieldInjections.java:74)
at app//org.neo4j.procedure.impl.ProcedureCompiler.compileProcedure(ProcedureCompiler.java:248)
at app//org.neo4j.procedure.impl.ProcedureCompiler.compileProcedure(ProcedureCompiler.java:207)
at app//org.neo4j.procedure.impl.ProcedureCompiler.compileProcedure(ProcedureCompiler.java:291)
at app//org.neo4j.procedure.impl.GlobalProceduresRegistry.registerProcedure(GlobalProceduresRegistry.java:164)
at app//org.neo4j.procedure.impl.GlobalProceduresRegistry.registerProcedure(GlobalProceduresRegistry.java:154)
at app//org.neo4j.harness.internal.HarnessRegisteredProcs.applyTo(HarnessRegisteredProcs.java:46)
at app//org.neo4j.harness.internal.AbstractInProcessNeo4jBuilder$Neo4jHarnessExtensions$1.start(AbstractInProcessNeo4jBuilder.java:269)
at app//org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:353)
... 78 more
Do I need to add any more dependencies or I am missing somewhere?
Thanks in advance!
Regards,
Siba