pig-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From roh...@apache.org
Subject svn commit: r1796354 - in /pig/trunk: CHANGES.txt contrib/piggybank/java/src/main/java/org/apache/pig/piggybank/storage/avro/AvroStorage.java
Date Fri, 26 May 2017 22:16:47 GMT
Author: rohini
Date: Fri May 26 22:16:47 2017
New Revision: 1796354

URL: http://svn.apache.org/viewvc?rev=1796354&view=rev
Log:
PIG-5236: json simple jar not included automatically with piggybank AvroStorage (satishsaley
via rohini)

Modified:
    pig/trunk/CHANGES.txt
    pig/trunk/contrib/piggybank/java/src/main/java/org/apache/pig/piggybank/storage/avro/AvroStorage.java

Modified: pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1796354&r1=1796353&r2=1796354&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Fri May 26 22:16:47 2017
@@ -36,6 +36,8 @@ PIG-5067: Revisit union on numeric type
  
 IMPROVEMENTS
 
+PIG-5236: json simple jar not included automatically with piggybank AvroStorage (satishsaley
via rohini)
+
 PIG-3103: make mockito a test dependency (instead of compile) (nkollar via szita)
 
 PIG-3021: Split results missing records when there is null values in the column comparison
(jeffjee617, cheolsoo via daijy)

Modified: pig/trunk/contrib/piggybank/java/src/main/java/org/apache/pig/piggybank/storage/avro/AvroStorage.java
URL: http://svn.apache.org/viewvc/pig/trunk/contrib/piggybank/java/src/main/java/org/apache/pig/piggybank/storage/avro/AvroStorage.java?rev=1796354&r1=1796353&r2=1796354&view=diff
==============================================================================
--- pig/trunk/contrib/piggybank/java/src/main/java/org/apache/pig/piggybank/storage/avro/AvroStorage.java
(original)
+++ pig/trunk/contrib/piggybank/java/src/main/java/org/apache/pig/piggybank/storage/avro/AvroStorage.java
Fri May 26 22:16:47 2017
@@ -55,7 +55,9 @@ import org.apache.pig.ResourceSchema;
 import org.apache.pig.ResourceStatistics;
 import org.apache.pig.StoreFunc;
 import org.apache.pig.StoreFuncInterface;
+import org.apache.pig.StoreResources;
 import org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.PigSplit;
+import org.apache.pig.builtin.FuncUtils;
 import org.apache.pig.data.Tuple;
 import org.apache.pig.impl.util.ObjectSerializer;
 import org.apache.pig.impl.util.UDFContext;
@@ -67,7 +69,7 @@ import org.json.simple.parser.ParseExcep
  * AvroStorage is used to load/store Avro data <br/>
  * Document can be found <a href='https://cwiki.apache.org/PIG/avrostorage.html'>here</a>
  */
-public class AvroStorage extends FileInputLoadFunc implements StoreFuncInterface, LoadMetadata
{
+public class AvroStorage extends FileInputLoadFunc implements StoreFuncInterface, LoadMetadata,
StoreResources {
 
     private static final Log LOG = LogFactory.getLog(AvroStorage.class);
     /* storeFunc parameters */
@@ -812,4 +814,11 @@ public class AvroStorage extends FileInp
             e.printStackTrace();
         }
     }
+
+    @Override
+    public List<String> getShipFiles() {
+        ArrayList<Class> classList = new ArrayList<Class>();
+        classList.add(JSONParser.class);
+        return FuncUtils.getShipFiles(classList);
+    }
 }



Mime
View raw message