From 2de97e9e61f8a69b564a350b0f624bdb297ac36e Mon Sep 17 00:00:00 2001 From: David Garcia Date: Mon, 5 Dec 2022 09:00:27 +0100 Subject: [PATCH] #313 datum writer changed to final --- .../kloadgen/serializer/GenericAvroRecordBinarySerializer.java | 2 +- .../coru/kloadgen/serializer/GenericAvroRecordSerializer.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/net/coru/kloadgen/serializer/GenericAvroRecordBinarySerializer.java b/src/main/java/net/coru/kloadgen/serializer/GenericAvroRecordBinarySerializer.java index 0363ab57..a7edf995 100644 --- a/src/main/java/net/coru/kloadgen/serializer/GenericAvroRecordBinarySerializer.java +++ b/src/main/java/net/coru/kloadgen/serializer/GenericAvroRecordBinarySerializer.java @@ -24,7 +24,7 @@ public class GenericAvroRecordBinarySerializer implemen @Override public final byte[] serialize(final String s, final T data) { - DatumWriter writer; + final DatumWriter writer; if (data instanceof SpecificRecord) { writer = new SpecificDatumWriter<>(data.getSchema()); } else { diff --git a/src/main/java/net/coru/kloadgen/serializer/GenericAvroRecordSerializer.java b/src/main/java/net/coru/kloadgen/serializer/GenericAvroRecordSerializer.java index dc4cca0a..5389f9c0 100644 --- a/src/main/java/net/coru/kloadgen/serializer/GenericAvroRecordSerializer.java +++ b/src/main/java/net/coru/kloadgen/serializer/GenericAvroRecordSerializer.java @@ -26,7 +26,7 @@ public class GenericAvroRecordSerializer implements Ser @Override public final byte[] serialize(final String topic, final T data) { - DatumWriter writer; + final DatumWriter writer; if (data instanceof SpecificRecord) { writer = new SpecificDatumWriter<>(data.getSchema()); } else {