diff --git a/testkit-backend/pom.xml b/testkit-backend/pom.xml index 20d42658ed..d7fb8f9ae2 100644 --- a/testkit-backend/pom.xml +++ b/testkit-backend/pom.xml @@ -61,7 +61,10 @@ org.apache.maven.plugins maven-compiler-plugin - + + -Xlint:all,-processing + -Werror + diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/CustomDriverError.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/CustomDriverError.java index 652d66fd4b..17cb576f33 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/CustomDriverError.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/CustomDriverError.java @@ -18,7 +18,12 @@ */ package neo4j.org.testkit.backend; +import java.io.Serial; + public class CustomDriverError extends RuntimeException { + @Serial + private static final long serialVersionUID = 2979071989786663535L; + public CustomDriverError(Throwable cause) { super(cause); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/FrontendError.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/FrontendError.java index bf8b1b9594..63ca3c2bc9 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/FrontendError.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/FrontendError.java @@ -18,4 +18,9 @@ */ package neo4j.org.testkit.backend; -public class FrontendError extends RuntimeException {} +import java.io.Serial; + +public class FrontendError extends RuntimeException { + @Serial + private static final long serialVersionUID = -8369933385092563391L; +} diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxResultHolder.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxResultHolder.java index 1fe61d249e..db7e34e7bf 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxResultHolder.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxResultHolder.java @@ -26,6 +26,7 @@ import org.neo4j.driver.Record; import org.neo4j.driver.reactive.RxResult; +@SuppressWarnings("deprecation") public class RxResultHolder extends AbstractResultHolder { @Setter private RxBufferedSubscriber subscriber; diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxSessionHolder.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxSessionHolder.java index 2156a153dc..ad64081d58 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxSessionHolder.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxSessionHolder.java @@ -21,6 +21,7 @@ import org.neo4j.driver.SessionConfig; import org.neo4j.driver.reactive.RxSession; +@SuppressWarnings("deprecation") public class RxSessionHolder extends AbstractSessionHolder { public RxSessionHolder(DriverHolder driverHolder, RxSession session, SessionConfig config) { super(driverHolder, session, config); diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxTransactionHolder.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxTransactionHolder.java index fe36e926d4..d2e55397da 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxTransactionHolder.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/holder/RxTransactionHolder.java @@ -20,6 +20,7 @@ import org.neo4j.driver.reactive.RxTransaction; +@SuppressWarnings("deprecation") public class RxTransactionHolder extends AbstractTransactionHolder { public RxTransactionHolder(RxSessionHolder sessionHolder, RxTransaction transaction) { super(sessionHolder, transaction); diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/TestkitModule.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/TestkitModule.java index 26b1880ba5..c31f72774e 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/TestkitModule.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/TestkitModule.java @@ -19,6 +19,7 @@ package neo4j.org.testkit.backend.messages; import com.fasterxml.jackson.databind.module.SimpleModule; +import java.io.Serial; import java.time.LocalDate; import java.util.List; import neo4j.org.testkit.backend.messages.requests.deserializer.TestkitCypherDateDeserializer; @@ -57,6 +58,9 @@ import org.neo4j.driver.types.IsoDuration; public class TestkitModule extends SimpleModule { + @Serial + private static final long serialVersionUID = 7051732358423895087L; + public TestkitModule() { this.addDeserializer(List.class, new TestkitListDeserializer()); this.addDeserializer(CypherDateTime.class, new TestkitCypherDateTimeDeserializer()); diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/NewSession.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/NewSession.java index 8078c1b033..1c25738381 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/NewSession.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/NewSession.java @@ -105,6 +105,7 @@ private AsyncSessionHolder createAsyncSessionState(DriverHolder driverHolder, Se driverHolder, driverHolder.getDriver().asyncSession(sessionConfig), sessionConfig); } + @SuppressWarnings("deprecation") private RxSessionHolder createRxSessionState(DriverHolder driverHolder, SessionConfig sessionConfig) { return new RxSessionHolder(driverHolder, driverHolder.getDriver().rxSession(sessionConfig), sessionConfig); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionBeginTransaction.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionBeginTransaction.java index 264797edd7..608a273814 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionBeginTransaction.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionBeginTransaction.java @@ -88,6 +88,7 @@ public CompletionStage processAsync(TestkitState testkitState) } @Override + @SuppressWarnings("deprecation") public Mono processRx(TestkitState testkitState) { return testkitState.getRxSessionHolder(data.getSessionId()).flatMap(sessionHolder -> { RxSession session = sessionHolder.getSession(); diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionLastBookmarks.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionLastBookmarks.java index 50e42c8d81..e1a5d8ecca 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionLastBookmarks.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionLastBookmarks.java @@ -50,6 +50,7 @@ public CompletionStage processAsync(TestkitState testkitState) } @Override + @SuppressWarnings("deprecation") public Mono processRx(TestkitState testkitState) { return testkitState .getRxSessionHolder(data.getSessionId()) diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionReadTransaction.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionReadTransaction.java index 0203edf84a..13a00fd509 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionReadTransaction.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionReadTransaction.java @@ -48,6 +48,7 @@ public class SessionReadTransaction implements TestkitRequest { private SessionReadTransactionBody data; @Override + @SuppressWarnings("deprecation") public TestkitResponse process(TestkitState testkitState) { SessionHolder sessionHolder = testkitState.getSessionHolder(data.getSessionId()); Session session = sessionHolder.getSession(); @@ -56,6 +57,7 @@ public TestkitResponse process(TestkitState testkitState) { } @Override + @SuppressWarnings("deprecation") public CompletionStage processAsync(TestkitState testkitState) { return testkitState .getAsyncSessionHolder(data.getSessionId()) @@ -77,6 +79,7 @@ public CompletionStage processAsync(TestkitState testkitState) } @Override + @SuppressWarnings("deprecation") public Mono processRx(TestkitState testkitState) { return testkitState .getRxSessionHolder(data.getSessionId()) @@ -113,6 +116,7 @@ public Mono processReactive(TestkitState testkitState) { .then(Mono.just(retryableDone())); } + @SuppressWarnings("deprecation") private TransactionWork handle(TestkitState testkitState, SessionHolder sessionHolder) { return tx -> { String txId = testkitState.addTransactionHolder(new TransactionHolder(sessionHolder, tx)); diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionRun.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionRun.java index 88857ed1ba..8624fd3e39 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionRun.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionRun.java @@ -99,6 +99,7 @@ public CompletionStage processAsync(TestkitState testkitState) } @Override + @SuppressWarnings("deprecation") public Mono processRx(TestkitState testkitState) { return testkitState.getRxSessionHolder(data.getSessionId()).flatMap(sessionHolder -> { RxSession session = sessionHolder.getSession(); diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionWriteTransaction.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionWriteTransaction.java index 50803689fc..6effd93b95 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionWriteTransaction.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/SessionWriteTransaction.java @@ -49,6 +49,7 @@ public class SessionWriteTransaction implements TestkitRequest { private SessionWriteTransactionBody data; @Override + @SuppressWarnings("deprecation") public TestkitResponse process(TestkitState testkitState) { SessionHolder sessionHolder = testkitState.getSessionHolder(data.getSessionId()); Session session = sessionHolder.getSession(); @@ -57,6 +58,7 @@ public TestkitResponse process(TestkitState testkitState) { } @Override + @SuppressWarnings("deprecation") public CompletionStage processAsync(TestkitState testkitState) { return testkitState .getAsyncSessionHolder(data.getSessionId()) @@ -78,6 +80,7 @@ public CompletionStage processAsync(TestkitState testkitState) } @Override + @SuppressWarnings("deprecation") public Mono processRx(TestkitState testkitState) { return testkitState .getRxSessionHolder(data.getSessionId()) @@ -114,6 +117,7 @@ public Mono processReactive(TestkitState testkitState) { .then(Mono.just(retryableDone())); } + @SuppressWarnings("deprecation") private TransactionWork handle(TestkitState testkitState, SessionHolder sessionHolder) { return tx -> { String txId = testkitState.addTransactionHolder(new TransactionHolder(sessionHolder, tx)); diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/TransactionClose.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/TransactionClose.java index 7432944971..8a75db4f10 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/TransactionClose.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/TransactionClose.java @@ -49,6 +49,7 @@ public CompletionStage processAsync(TestkitState testkitState) } @Override + @SuppressWarnings("deprecation") public Mono processRx(TestkitState testkitState) { return testkitState .getRxTransactionHolder(data.getTxId()) diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/TransactionRun.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/TransactionRun.java index 9617d8af5e..b7d07c4fb7 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/TransactionRun.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/TransactionRun.java @@ -66,6 +66,7 @@ public CompletionStage processAsync(TestkitState testkitState) } @Override + @SuppressWarnings("deprecation") public Mono processRx(TestkitState testkitState) { return testkitState.getRxTransactionHolder(data.getTxId()).flatMap(transactionHolder -> { RxResult result = transactionHolder diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDateDeserializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDateDeserializer.java index 7d4247f7ef..c4a37329e8 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDateDeserializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDateDeserializer.java @@ -23,11 +23,15 @@ import com.fasterxml.jackson.databind.DeserializationContext; import com.fasterxml.jackson.databind.deser.std.StdDeserializer; import java.io.IOException; +import java.io.Serial; import java.time.LocalDate; import java.util.Date; public class TestkitCypherDateDeserializer extends StdDeserializer { + @Serial + private static final long serialVersionUID = 3489940766207129614L; + private final TestkitCypherTypeMapper mapper; public TestkitCypherDateDeserializer() { diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDateTimeDeserializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDateTimeDeserializer.java index 97e59e7210..936592ad90 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDateTimeDeserializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDateTimeDeserializer.java @@ -23,9 +23,13 @@ import com.fasterxml.jackson.databind.DeserializationContext; import com.fasterxml.jackson.databind.deser.std.StdDeserializer; import java.io.IOException; +import java.io.Serial; import neo4j.org.testkit.backend.messages.requests.deserializer.types.CypherDateTime; public class TestkitCypherDateTimeDeserializer extends StdDeserializer { + @Serial + private static final long serialVersionUID = 8980981682742682436L; + private final TestkitCypherTypeMapper mapper; public TestkitCypherDateTimeDeserializer() { diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDurationDeserializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDurationDeserializer.java index b1d7fb49bf..30d9fe32bf 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDurationDeserializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherDurationDeserializer.java @@ -23,10 +23,14 @@ import com.fasterxml.jackson.databind.DeserializationContext; import com.fasterxml.jackson.databind.deser.std.StdDeserializer; import java.io.IOException; +import java.io.Serial; import org.neo4j.driver.internal.InternalIsoDuration; import org.neo4j.driver.types.IsoDuration; public class TestkitCypherDurationDeserializer extends StdDeserializer { + @Serial + private static final long serialVersionUID = 3128342779161014747L; + private final TestkitCypherTypeMapper mapper; public TestkitCypherDurationDeserializer() { diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherParamDeserializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherParamDeserializer.java index b5740d0db0..92e2d9eb49 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherParamDeserializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherParamDeserializer.java @@ -26,12 +26,16 @@ import com.fasterxml.jackson.databind.DeserializationContext; import com.fasterxml.jackson.databind.deser.std.StdDeserializer; import java.io.IOException; +import java.io.Serial; import java.util.Collections; import java.util.HashMap; import java.util.Map; import neo4j.org.testkit.backend.messages.requests.deserializer.types.CypherType; public class TestkitCypherParamDeserializer extends StdDeserializer> { + @Serial + private static final long serialVersionUID = -3239342714470961079L; + public TestkitCypherParamDeserializer() { super(Map.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherTimeDeserializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherTimeDeserializer.java index 1717568b5c..4c8f6b07f1 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherTimeDeserializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitCypherTimeDeserializer.java @@ -23,9 +23,13 @@ import com.fasterxml.jackson.databind.DeserializationContext; import com.fasterxml.jackson.databind.deser.std.StdDeserializer; import java.io.IOException; +import java.io.Serial; import neo4j.org.testkit.backend.messages.requests.deserializer.types.CypherTime; public class TestkitCypherTimeDeserializer extends StdDeserializer { + @Serial + private static final long serialVersionUID = 8354352358618500970L; + private final TestkitCypherTypeMapper mapper; public TestkitCypherTimeDeserializer() { diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitListDeserializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitListDeserializer.java index e5dacda40b..4f412a28b6 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitListDeserializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/requests/deserializer/TestkitListDeserializer.java @@ -26,11 +26,15 @@ import com.fasterxml.jackson.databind.DeserializationContext; import com.fasterxml.jackson.databind.deser.std.StdDeserializer; import java.io.IOException; +import java.io.Serial; import java.util.ArrayList; import java.util.List; import neo4j.org.testkit.backend.messages.requests.deserializer.types.CypherType; public class TestkitListDeserializer extends StdDeserializer> { + @Serial + private static final long serialVersionUID = -1878499456593526741L; + private final TestkitCypherParamDeserializer mapDeserializer; public TestkitListDeserializer() { diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDateTimeValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDateTimeValueSerializer.java index c40fef3fd5..80f422e1e6 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDateTimeValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDateTimeValueSerializer.java @@ -24,12 +24,16 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.time.ZoneId; import java.time.ZoneOffset; import java.time.ZonedDateTime; import org.neo4j.driver.internal.value.DateTimeValue; public class TestkitDateTimeValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 819438767898259613L; + public TestkitDateTimeValueSerializer() { super(DateTimeValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDateValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDateValueSerializer.java index 32c9f297fc..7453177776 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDateValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDateValueSerializer.java @@ -24,10 +24,14 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.time.LocalDate; import org.neo4j.driver.internal.value.DateValue; public class TestkitDateValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 6317556585191107633L; + public TestkitDateValueSerializer() { super(DateValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDurationValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDurationValueSerializer.java index 23df07f2a4..61198bccea 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDurationValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitDurationValueSerializer.java @@ -24,10 +24,14 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import org.neo4j.driver.internal.value.DurationValue; import org.neo4j.driver.types.IsoDuration; public class TestkitDurationValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = -4371898769147355036L; + public TestkitDurationValueSerializer() { super(DurationValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitListValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitListValueSerializer.java index 31d8c96e08..86a1472726 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitListValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitListValueSerializer.java @@ -25,10 +25,14 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.util.function.Function; import org.neo4j.driver.internal.value.ListValue; public class TestkitListValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = -5564826952797323279L; + public TestkitListValueSerializer() { super(ListValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitLocalDateTimeValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitLocalDateTimeValueSerializer.java index edf52f8292..d4168fae15 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitLocalDateTimeValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitLocalDateTimeValueSerializer.java @@ -24,10 +24,14 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.time.LocalDateTime; import org.neo4j.driver.internal.value.LocalDateTimeValue; public class TestkitLocalDateTimeValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 8864167921883077348L; + public TestkitLocalDateTimeValueSerializer() { super(LocalDateTimeValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitLocalTimeValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitLocalTimeValueSerializer.java index 84a6e9f4a7..6ed7d43d26 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitLocalTimeValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitLocalTimeValueSerializer.java @@ -24,10 +24,14 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.time.LocalTime; import org.neo4j.driver.internal.value.LocalTimeValue; public class TestkitLocalTimeValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = -3712440793854179552L; + public TestkitLocalTimeValueSerializer() { super(LocalTimeValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitMapValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitMapValueSerializer.java index b9487563d7..c4c4d88fa0 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitMapValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitMapValueSerializer.java @@ -25,12 +25,16 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.util.Map; import java.util.function.Function; import org.neo4j.driver.Value; import org.neo4j.driver.internal.value.MapValue; public class TestkitMapValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 3405706388191274032L; + public TestkitMapValueSerializer() { super(MapValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitNodeValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitNodeValueSerializer.java index 595fc6c62f..1c1ce64bb3 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitNodeValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitNodeValueSerializer.java @@ -24,6 +24,7 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.util.function.Function; import java.util.function.Supplier; import java.util.stream.StreamSupport; @@ -35,11 +36,15 @@ import org.neo4j.driver.types.Node; public class TestkitNodeValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 5456264010641357998L; + public TestkitNodeValueSerializer() { super(NodeValue.class); } @Override + @SuppressWarnings("deprecation") public void serialize(NodeValue nodeValue, JsonGenerator gen, SerializerProvider serializerProvider) throws IOException { diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitPathValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitPathValueSerializer.java index 3918ea8d52..30fe5e1c95 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitPathValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitPathValueSerializer.java @@ -24,6 +24,7 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.util.stream.StreamSupport; import org.neo4j.driver.internal.value.ListValue; import org.neo4j.driver.internal.value.NodeValue; @@ -32,6 +33,9 @@ import org.neo4j.driver.types.Path; public class TestkitPathValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = -6937949051813143300L; + public TestkitPathValueSerializer() { super(PathValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitRecordSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitRecordSerializer.java index 356ecd2813..727d52c447 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitRecordSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitRecordSerializer.java @@ -24,10 +24,14 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import org.neo4j.driver.Record; public class TestkitRecordSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 5412627390969023151L; + public TestkitRecordSerializer() { super(org.neo4j.driver.Record.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitRelationshipValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitRelationshipValueSerializer.java index 9c1c2ad05f..0599bf1c21 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitRelationshipValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitRelationshipValueSerializer.java @@ -24,6 +24,7 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.util.function.Function; import java.util.function.Supplier; import org.neo4j.driver.internal.value.IntegerValue; @@ -33,11 +34,15 @@ import org.neo4j.driver.types.Relationship; public class TestkitRelationshipValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 7011005216175127691L; + public TestkitRelationshipValueSerializer() { super(RelationshipValue.class); } @Override + @SuppressWarnings("deprecation") public void serialize(RelationshipValue relationshipValue, JsonGenerator gen, SerializerProvider provider) throws IOException { cypherObject(gen, "Relationship", () -> { diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitTimeValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitTimeValueSerializer.java index 46fe0d21c0..d8bd5b2403 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitTimeValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitTimeValueSerializer.java @@ -24,10 +24,14 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import java.time.OffsetTime; import org.neo4j.driver.internal.value.TimeValue; public class TestkitTimeValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 9147804953543296762L; + public TestkitTimeValueSerializer() { super(TimeValue.class); } diff --git a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitValueSerializer.java b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitValueSerializer.java index 91d8633d39..5dc1e3ba3d 100644 --- a/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitValueSerializer.java +++ b/testkit-backend/src/main/java/neo4j/org/testkit/backend/messages/responses/serializer/TestkitValueSerializer.java @@ -24,10 +24,14 @@ import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.ser.std.StdSerializer; import java.io.IOException; +import java.io.Serial; import org.neo4j.driver.Value; import org.neo4j.driver.internal.types.InternalTypeSystem; public class TestkitValueSerializer extends StdSerializer { + @Serial + private static final long serialVersionUID = 6125358719511809365L; + public TestkitValueSerializer() { super(Value.class); }