diff --git ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFJSONTuple.java ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFJSONTuple.java index 5fa62a2..34911b0 100644 --- ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFJSONTuple.java +++ ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFJSONTuple.java @@ -93,7 +93,7 @@ protected boolean removeEldestEntry(Map.Entry eldest) { } - static Map jsonObjectCache = new HashCache(); + private transient Map jsonObjectCache; @Override public void close() throws HiveException { @@ -105,6 +105,7 @@ public StructObjectInspector initialize(ObjectInspector[] args) inputOIs = args; numCols = args.length - 1; + jsonObjectCache = new HashCache<>(); if (numCols < 1) { throw new UDFArgumentException("json_tuple() takes at least two arguments: " +