AVRO-1879: Make conversions field static.
Project: http://git-wip-us.apache.org/repos/asf/avro/repo Commit: http://git-wip-us.apache.org/repos/asf/avro/commit/988a3790 Tree: http://git-wip-us.apache.org/repos/asf/avro/tree/988a3790 Diff: http://git-wip-us.apache.org/repos/asf/avro/diff/988a3790 Branch: refs/heads/branch-1.8 Commit: 988a3790eef104642546fb9bef8a4cae5a148558 Parents: 1c9ef72 Author: Michael Wong <[email protected]> Authored: Mon Jul 11 23:56:23 2016 +0100 Committer: Ryan Blue <[email protected]> Committed: Sat Nov 5 13:15:13 2016 -0700 ---------------------------------------------------------------------- CHANGES.txt | 2 ++ .../apache/avro/compiler/specific/templates/java/classic/record.vm | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/avro/blob/988a3790/CHANGES.txt ---------------------------------------------------------------------- diff --git a/CHANGES.txt b/CHANGES.txt index 537b2b2..2242785 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -19,6 +19,8 @@ Trunk (not yet released) AVRO-1719: C++: Fix tests with Boost >= 1.59. (Romain Geissler via blue) + AVRO-1879: Make conversions field static. (Michael Wong via blue) + BUG FIXES AVRO-1741: Python3: Fix error when codec is not in the header. http://git-wip-us.apache.org/repos/asf/avro/blob/988a3790/lang/java/compiler/src/main/velocity/org/apache/avro/compiler/specific/templates/java/classic/record.vm ---------------------------------------------------------------------- diff --git a/lang/java/compiler/src/main/velocity/org/apache/avro/compiler/specific/templates/java/classic/record.vm b/lang/java/compiler/src/main/velocity/org/apache/avro/compiler/specific/templates/java/classic/record.vm index 1f99f38..1170d79 100644 --- a/lang/java/compiler/src/main/velocity/org/apache/avro/compiler/specific/templates/java/classic/record.vm +++ b/lang/java/compiler/src/main/velocity/org/apache/avro/compiler/specific/templates/java/classic/record.vm @@ -138,7 +138,7 @@ public class ${this.mangle($schema.getName())}#if ($schema.isError()) extends or protected static final org.apache.avro.data.TimeConversions.TimestampConversion TIMESTAMP_CONVERSION = new org.apache.avro.data.TimeConversions.TimestampConversion(); protected static final org.apache.avro.Conversions.DecimalConversion DECIMAL_CONVERSION = new org.apache.avro.Conversions.DecimalConversion(); - private final org.apache.avro.Conversion<?>[] conversions = + private static final org.apache.avro.Conversion<?>[] conversions = new org.apache.avro.Conversion<?>[] { #foreach ($field in $schema.getFields()) ${this.conversionInstance($field.schema())},
