From b3562183f7cfc948b0fb6f4695fb265c4d13908a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20J=C3=A4derberg?= Date: Mon, 22 Jan 2024 14:22:41 +0100 Subject: [PATCH] Fix 5.16 version selection --- .../neo4j/gds/compat/_516/Neo4jProxyFactoryImpl.java | 2 +- .../gds/compat/_516/InMemoryStorageEngineFactory.java | 2 +- .../compat/_516/StorageEngineProxyFactoryImpl.java | 2 +- .../src/test/java/org/neo4j/gds/SysInfoProcTest.java | 11 +++++++++++ 4 files changed, 14 insertions(+), 3 deletions(-) diff --git a/compatibility/5.16/neo4j-kernel-adapter/src/main/java17/org/neo4j/gds/compat/_516/Neo4jProxyFactoryImpl.java b/compatibility/5.16/neo4j-kernel-adapter/src/main/java17/org/neo4j/gds/compat/_516/Neo4jProxyFactoryImpl.java index f3828f53b1..abf5b5d9e0 100644 --- a/compatibility/5.16/neo4j-kernel-adapter/src/main/java17/org/neo4j/gds/compat/_516/Neo4jProxyFactoryImpl.java +++ b/compatibility/5.16/neo4j-kernel-adapter/src/main/java17/org/neo4j/gds/compat/_516/Neo4jProxyFactoryImpl.java @@ -29,7 +29,7 @@ public final class Neo4jProxyFactoryImpl implements Neo4jProxyFactory { @Override public boolean canLoad(Neo4jVersion version) { - return version == Neo4jVersion.V_Dev; + return version == Neo4jVersion.V_5_16; } @Override diff --git a/compatibility/5.16/storage-engine-adapter/src/main/java17/org/neo4j/gds/compat/_516/InMemoryStorageEngineFactory.java b/compatibility/5.16/storage-engine-adapter/src/main/java17/org/neo4j/gds/compat/_516/InMemoryStorageEngineFactory.java index 806f8c3758..f6e36de161 100644 --- a/compatibility/5.16/storage-engine-adapter/src/main/java17/org/neo4j/gds/compat/_516/InMemoryStorageEngineFactory.java +++ b/compatibility/5.16/storage-engine-adapter/src/main/java17/org/neo4j/gds/compat/_516/InMemoryStorageEngineFactory.java @@ -120,7 +120,7 @@ public class InMemoryStorageEngineFactory implements StorageEngineFactory { static final String IN_MEMORY_STORAGE_ENGINE_NAME = "in-memory-516"; public InMemoryStorageEngineFactory() { - StorageEngineProxyApi.requireNeo4jVersion(Neo4jVersion.V_Dev, StorageEngineFactory.class); + StorageEngineProxyApi.requireNeo4jVersion(Neo4jVersion.V_5_16, StorageEngineFactory.class); } @Override diff --git a/compatibility/5.16/storage-engine-adapter/src/main/java17/org/neo4j/gds/compat/_516/StorageEngineProxyFactoryImpl.java b/compatibility/5.16/storage-engine-adapter/src/main/java17/org/neo4j/gds/compat/_516/StorageEngineProxyFactoryImpl.java index bd9c78e5da..db087b9283 100644 --- a/compatibility/5.16/storage-engine-adapter/src/main/java17/org/neo4j/gds/compat/_516/StorageEngineProxyFactoryImpl.java +++ b/compatibility/5.16/storage-engine-adapter/src/main/java17/org/neo4j/gds/compat/_516/StorageEngineProxyFactoryImpl.java @@ -29,7 +29,7 @@ public class StorageEngineProxyFactoryImpl implements StorageEngineProxyFactory @Override public boolean canLoad(Neo4jVersion version) { - return version == Neo4jVersion.V_Dev; + return version == Neo4jVersion.V_5_16; } @Override diff --git a/proc/sysinfo/src/test/java/org/neo4j/gds/SysInfoProcTest.java b/proc/sysinfo/src/test/java/org/neo4j/gds/SysInfoProcTest.java index c8eefd42c5..bb1bbbbe4d 100644 --- a/proc/sysinfo/src/test/java/org/neo4j/gds/SysInfoProcTest.java +++ b/proc/sysinfo/src/test/java/org/neo4j/gds/SysInfoProcTest.java @@ -87,6 +87,9 @@ class SysInfoProcTest extends BaseProcTest { "Neo4j 5.15", "Neo4j 5.15 (placeholder)", + "Neo4j 5.16", + "Neo4j 5.16 (placeholder)", + "Neo4j DEV", "Neo4j DEV (placeholder)", @@ -223,6 +226,14 @@ void testSysInfoProc() throws IOException { "Neo4j 5.15" ); break; + case V_5_16: + expectedCompatibilities = Set.of( + "Neo4j Settings 5.x (placeholder)", + "Neo4j Settings 5.x", + "Neo4j 5.16 (placeholder)", + "Neo4j 5.16" + ); + break; case V_Dev: expectedCompatibilities = Set.of( "Neo4j Settings 5.x",