hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From na...@apache.org
Subject svn commit: r1451261 - in /hive/trunk/ql/src: java/org/apache/hadoop/hive/ql/exec/ java/org/apache/hadoop/hive/ql/udf/generic/ test/org/apache/hadoop/hive/ql/udf/generic/ test/queries/clientpositive/ test/results/clientpositive/
Date Thu, 28 Feb 2013 17:27:33 GMT
Author: namit
Date: Thu Feb 28 17:27:32 2013
New Revision: 1451261

URL: http://svn.apache.org/r1451261
Log:
HIVE-3628 Provide a way to use counters in Hive through UDF
(Navis via namit)


Added:
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/MapredContext.java
    hive/trunk/ql/src/test/org/apache/hadoop/hive/ql/udf/generic/DummyContextUDF.java
    hive/trunk/ql/src/test/queries/clientpositive/udf_context_aware.q
    hive/trunk/ql/src/test/results/clientpositive/udf_context_aware.q.out
Modified:
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecMapper.java
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecReducer.java
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExprNodeGenericFuncEvaluator.java
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/GroupByOperator.java
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/UDTFOperator.java
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDAFEvaluator.java
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDF.java
    hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTF.java

Modified: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecMapper.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecMapper.java?rev=1451261&r1=1451260&r2=1451261&view=diff
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecMapper.java (original)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecMapper.java Thu Feb 28 17:27:32
2013
@@ -94,6 +94,8 @@ public class ExecMapper extends MapReduc
       localWork = mrwork.getMapLocalWork();
       execContext.setLocalWork(localWork);
 
+      MapredContext.init(true, new JobConf(jc));
+
       mo.setExecContext(execContext);
       mo.initializeLocalWork(jc);
       mo.initialize(jc, null);
@@ -131,6 +133,7 @@ public class ExecMapper extends MapReduc
       mo.setOutputCollector(oc);
       mo.setReporter(rp);
       mo.setOperatorHooks(opHooks);
+      MapredContext.get().setReporter(reporter);
     }
     // reset the execContext for each new row
     execContext.resetRow();
@@ -226,6 +229,8 @@ public class ExecMapper extends MapReduc
         l4j.error("Hit error while closing operators - failing tree");
         throw new RuntimeException("Hive Runtime Error while closing operators", e);
       }
+    } finally {
+      MapredContext.close();
     }
   }
 
@@ -257,8 +262,8 @@ public class ExecMapper extends MapReduc
     }
 
     public void func(Operator op) {
-      Map<Enum, Long> opStats = op.getStats();
-      for (Map.Entry<Enum, Long> e : opStats.entrySet()) {
+      Map<Enum<?>, Long> opStats = op.getStats();
+      for (Map.Entry<Enum<?>, Long> e : opStats.entrySet()) {
         if (rp != null) {
           rp.incrCounter(e.getKey(), e.getValue());
         }

Modified: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecReducer.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecReducer.java?rev=1451261&r1=1451260&r2=1451261&view=diff
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecReducer.java (original)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecReducer.java Thu Feb 28 17:27:32
2013
@@ -146,6 +146,8 @@ public class ExecReducer extends MapRedu
       throw new RuntimeException(e);
     }
 
+    MapredContext.init(false, new JobConf(jc));
+
     // initialize reduce operator tree
     try {
       l4j.info(reducer.dump(0));
@@ -182,6 +184,7 @@ public class ExecReducer extends MapRedu
       reducer.setOutputCollector(oc);
       reducer.setReporter(rp);
       reducer.setOperatorHooks(opHooks);
+      MapredContext.get().setReporter(reporter);
     }
 
     try {
@@ -317,6 +320,8 @@ public class ExecReducer extends MapRedu
         throw new RuntimeException("Hive Runtime Error while closing operators: "
             + e.getMessage(), e);
       }
+    } finally {
+      MapredContext.close();
     }
   }
 }

Modified: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExprNodeGenericFuncEvaluator.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExprNodeGenericFuncEvaluator.java?rev=1451261&r1=1451260&r2=1451261&view=diff
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExprNodeGenericFuncEvaluator.java
(original)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExprNodeGenericFuncEvaluator.java
Thu Feb 28 17:27:32 2013
@@ -134,6 +134,10 @@ public class ExprNodeGenericFuncEvaluato
       throw new HiveException(
         "Stateful expressions cannot be used inside of CASE");
     }
+    MapredContext context = MapredContext.get();
+    if (context != null) {
+      context.setup(genericUDF);
+    }
     this.outputOI = genericUDF.initializeAndFoldConstants(childrenOIs);
     return this.outputOI;
   }

Modified: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/GroupByOperator.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/GroupByOperator.java?rev=1451261&r1=1451260&r2=1451261&view=diff
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/GroupByOperator.java (original)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/GroupByOperator.java Thu Feb 28
17:27:32 2013
@@ -363,6 +363,12 @@ public class GroupByOperator extends Ope
     for (ExprNodeEvaluator keyField : keyFields) {
       objectInspectors.add(null);
     }
+    MapredContext context = MapredContext.get();
+    if (context != null) {
+      for (GenericUDAFEvaluator genericUDAFEvaluator : aggregationEvaluators) {
+        context.setup(genericUDAFEvaluator);
+      }
+    }
     for (int i = 0; i < aggregationEvaluators.length; i++) {
       ObjectInspector roi = aggregationEvaluators[i].init(conf.getAggregators()
           .get(i).getMode(), aggregationParameterObjectInspectors[i]);

Added: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/MapredContext.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/MapredContext.java?rev=1451261&view=auto
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/MapredContext.java (added)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/MapredContext.java Thu Feb 28 17:27:32
2013
@@ -0,0 +1,158 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.hadoop.hive.ql.exec;
+
+import java.io.Closeable;
+import java.io.IOException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDF;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDTF;
+import org.apache.hadoop.mapred.JobConf;
+import org.apache.hadoop.mapred.Reporter;
+
+/**
+ * Runtime context of MapredTask providing additional information to GenericUDF
+ */
+public class MapredContext {
+
+  private static final Log logger = LogFactory.getLog("MapredContext");
+  private static final ThreadLocal<MapredContext> contexts = new ThreadLocal<MapredContext>();
+
+  static MapredContext get() {
+    return contexts.get();
+  }
+
+  static MapredContext init(boolean isMap, JobConf jobConf) {
+    MapredContext context = new MapredContext(isMap, jobConf);
+    contexts.set(context);
+    return context;
+  }
+
+  static void close() {
+    MapredContext context = contexts.get();
+    if (context != null) {
+      context.closeAll();
+    }
+    contexts.remove();
+  }
+
+  private final boolean isMap;
+  private final JobConf jobConf;
+  private final List<Closeable> udfs;
+
+  private Reporter reporter;
+
+  private MapredContext(boolean isMap, JobConf jobConf) {
+    this.isMap = isMap;
+    this.jobConf = jobConf;
+    this.udfs = new ArrayList<Closeable>();
+  }
+
+  /**
+   * Returns whether the UDF is called from Map or Reduce task.
+   */
+  public boolean isMap() {
+    return isMap;
+  }
+
+  /**
+   * Returns Reporter, which is set right before reading the first row.
+   */
+  public Reporter getReporter() {
+    return reporter;
+  }
+
+  /**
+   * Returns JobConf.
+   */
+  public JobConf getJobConf() {
+    return jobConf;
+  }
+
+  void setReporter(Reporter reporter) {
+    this.reporter = reporter;
+  }
+
+  private void registerCloseable(Closeable closeable) {
+    udfs.add(closeable);
+  }
+
+  private void closeAll() {
+    for (Closeable eval : udfs) {
+      try {
+        eval.close();
+      } catch (IOException e) {
+        logger.info("Hit error while closing udf " + eval);
+      }
+    }
+    udfs.clear();
+  }
+
+  void setup(GenericUDF genericUDF) {
+    if (needConfigure(genericUDF)) {
+      genericUDF.configure(this);
+    }
+    if (needClose(genericUDF)) {
+      registerCloseable(genericUDF);
+    }
+  }
+
+  void setup(GenericUDAFEvaluator genericUDAF) {
+    if (needConfigure(genericUDAF)) {
+      genericUDAF.configure(this);
+    }
+    if (needClose(genericUDAF)) {
+      registerCloseable(genericUDAF);
+    }
+  }
+
+  void setup(GenericUDTF genericUDTF) {
+    if (needConfigure(genericUDTF)) {
+      genericUDTF.configure(this);
+    }
+    // close is called by UDTFOperator
+  }
+
+  private boolean needConfigure(Object func) {
+    try {
+      Method initMethod = func.getClass().getMethod("configure", MapredContext.class);
+      return initMethod.getDeclaringClass() != GenericUDF.class &&
+          initMethod.getDeclaringClass() != GenericUDAFEvaluator.class &&
+          initMethod.getDeclaringClass() != GenericUDTF.class;
+    } catch (Exception e) {
+      return false;
+    }
+  }
+
+  private boolean needClose(Closeable func) {
+    try {
+      Method closeMethod = func.getClass().getMethod("close");
+      return closeMethod.getDeclaringClass() != GenericUDF.class &&
+          closeMethod.getDeclaringClass() != GenericUDAFEvaluator.class;
+    } catch (Exception e) {
+      return false;
+    }
+  }
+}

Modified: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/UDTFOperator.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/UDTFOperator.java?rev=1451261&r1=1451260&r2=1451261&view=diff
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/UDTFOperator.java (original)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/UDTFOperator.java Thu Feb 28 17:27:32
2013
@@ -65,6 +65,11 @@ public class UDTFOperator extends Operat
       udtfInputOIs[i] = inputFields.get(i).getFieldObjectInspector();
     }
     objToSendToUDTF = new Object[inputFields.size()];
+
+    MapredContext context = MapredContext.get();
+    if (context != null) {
+      context.setup(conf.getGenericUDTF());
+    }
     StructObjectInspector udtfOutputOI = conf.getGenericUDTF().initialize(
         udtfInputOIs);
 

Modified: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDAFEvaluator.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDAFEvaluator.java?rev=1451261&r1=1451260&r2=1451261&view=diff
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDAFEvaluator.java
(original)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDAFEvaluator.java
Thu Feb 28 17:27:32 2013
@@ -18,6 +18,10 @@
 
 package org.apache.hadoop.hive.ql.udf.generic;
 
+import java.io.Closeable;
+import java.io.IOException;
+
+import org.apache.hadoop.hive.ql.exec.MapredContext;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.UDFType;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
@@ -35,7 +39,7 @@ import org.apache.hadoop.hive.serde2.obj
  * array<int>, array<array<int>> and so on (arbitrary levels of nesting).
  */
 @UDFType(deterministic = true)
-public abstract class GenericUDAFEvaluator {
+public abstract class GenericUDAFEvaluator implements Closeable {
 
   /**
    * Mode.
@@ -73,6 +77,15 @@ public abstract class GenericUDAFEvaluat
   }
 
   /**
+   * Additionally setup GenericUDAFEvaluator with MapredContext before initializing.
+   * This is only called in runtime of MapRedTask.
+   *
+   * @param context context
+   */
+  public void configure(MapredContext mapredContext) {
+  }
+
+  /**
    * Initialize the evaluator.
    * 
    * @param m
@@ -126,6 +139,13 @@ public abstract class GenericUDAFEvaluat
   public abstract void reset(AggregationBuffer agg) throws HiveException;
 
   /**
+   * Close GenericUDFEvaluator.
+   * This is only called in runtime of MapRedTask.
+   */
+  public void close() throws IOException {
+  }
+
+  /**
    * This function will be called by GroupByOperator when it sees a new input
    * row.
    * 

Modified: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDF.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDF.java?rev=1451261&r1=1451260&r2=1451261&view=diff
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDF.java (original)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDF.java Thu Feb 28
17:27:32 2013
@@ -18,6 +18,10 @@
 
 package org.apache.hadoop.hive.ql.udf.generic;
 
+import java.io.Closeable;
+import java.io.IOException;
+
+import org.apache.hadoop.hive.ql.exec.MapredContext;
 import org.apache.hadoop.hive.ql.exec.FunctionRegistry;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
@@ -39,7 +43,7 @@ import org.apache.hadoop.hive.serde2.obj
  * can do short-circuit evaluations using DeferedObject.
  */
 @UDFType(deterministic = true)
-public abstract class GenericUDF {
+public abstract class GenericUDF implements Closeable {
 
   /**
    * A Defered Object allows us to do lazy-evaluation and short-circuiting.
@@ -86,6 +90,15 @@ public abstract class GenericUDF {
       throws UDFArgumentException;
 
   /**
+   * Additionally setup GenericUDF with MapredContext before initializing.
+   * This is only called in runtime of MapRedTask.
+   *
+   * @param context context
+   */
+  public void configure(MapredContext context) {
+  }
+
+  /**
    * Initialize this GenericUDF.  Additionally, if the arguments are constant
    * and the function is eligible to be folded, then the constant value
    * returned by this UDF will be computed and stored in the
@@ -163,4 +176,10 @@ public abstract class GenericUDF {
    */
   public abstract String getDisplayString(String[] children);
 
+  /**
+   * Close GenericUDF.
+   * This is only called in runtime of MapRedTask.
+   */
+  public void close() throws IOException {
+  }
 }

Modified: hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTF.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTF.java?rev=1451261&r1=1451260&r2=1451261&view=diff
==============================================================================
--- hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTF.java (original)
+++ hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTF.java Thu Feb
28 17:27:32 2013
@@ -18,6 +18,7 @@
 
 package org.apache.hadoop.hive.ql.udf.generic;
 
+import org.apache.hadoop.hive.ql.exec.MapredContext;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
@@ -34,6 +35,15 @@ public abstract class GenericUDTF {
   Collector collector = null;
 
   /**
+   * Additionally setup GenericUDTF with MapredContext before initializing.
+   * This is only called in runtime of MapRedTask.
+   *
+   * @param context context
+   */
+  public void configure(MapredContext mapredContext) {
+  }
+
+  /**
    * Initialize this GenericUDTF. This will be called only once per instance.
    *
    * @param argOIs

Added: hive/trunk/ql/src/test/org/apache/hadoop/hive/ql/udf/generic/DummyContextUDF.java
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/test/org/apache/hadoop/hive/ql/udf/generic/DummyContextUDF.java?rev=1451261&view=auto
==============================================================================
--- hive/trunk/ql/src/test/org/apache/hadoop/hive/ql/udf/generic/DummyContextUDF.java (added)
+++ hive/trunk/ql/src/test/org/apache/hadoop/hive/ql/udf/generic/DummyContextUDF.java Thu
Feb 28 17:27:32 2013
@@ -0,0 +1,55 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.hadoop.hive.ql.udf.generic;
+
+import org.apache.hadoop.hive.ql.exec.MapredContext;
+import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
+import org.apache.hadoop.hive.ql.metadata.HiveException;
+import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
+import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
+import org.apache.hadoop.io.LongWritable;
+import org.apache.hadoop.mapred.Counters;
+import org.apache.hadoop.mapred.Reporter;
+
+public class DummyContextUDF extends GenericUDF {
+
+  private MapredContext context;
+  private LongWritable result = new LongWritable();
+
+  public ObjectInspector initialize(ObjectInspector[] arguments) throws UDFArgumentException
{
+    return PrimitiveObjectInspectorFactory.writableLongObjectInspector;
+  }
+
+  public Object evaluate(DeferredObject[] arguments) throws HiveException {
+    Reporter reporter = context.getReporter();
+    Counters.Counter counter = reporter.getCounter(
+        "org.apache.hadoop.mapred.Task$Counter", "MAP_INPUT_RECORDS");
+    result.set(counter.getValue());
+    return result;
+  }
+
+  public String getDisplayString(String[] children) {
+    return "dummy-func()";
+  }
+
+  @Override
+  public void configure(MapredContext context) {
+    this.context = context;
+  }
+}

Added: hive/trunk/ql/src/test/queries/clientpositive/udf_context_aware.q
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/test/queries/clientpositive/udf_context_aware.q?rev=1451261&view=auto
==============================================================================
--- hive/trunk/ql/src/test/queries/clientpositive/udf_context_aware.q (added)
+++ hive/trunk/ql/src/test/queries/clientpositive/udf_context_aware.q Thu Feb 28 17:27:32
2013
@@ -0,0 +1,5 @@
+create temporary function counter as 'org.apache.hadoop.hive.ql.udf.generic.DummyContextUDF';
+
+set hive.input.format = org.apache.hadoop.hive.ql.io.BucketizedHiveInputFormat;
+
+select *, counter(key) from src limit 20;

Added: hive/trunk/ql/src/test/results/clientpositive/udf_context_aware.q.out
URL: http://svn.apache.org/viewvc/hive/trunk/ql/src/test/results/clientpositive/udf_context_aware.q.out?rev=1451261&view=auto
==============================================================================
--- hive/trunk/ql/src/test/results/clientpositive/udf_context_aware.q.out (added)
+++ hive/trunk/ql/src/test/results/clientpositive/udf_context_aware.q.out Thu Feb 28 17:27:32
2013
@@ -0,0 +1,32 @@
+PREHOOK: query: create temporary function counter as 'org.apache.hadoop.hive.ql.udf.generic.DummyContextUDF'
+PREHOOK: type: CREATEFUNCTION
+POSTHOOK: query: create temporary function counter as 'org.apache.hadoop.hive.ql.udf.generic.DummyContextUDF'
+POSTHOOK: type: CREATEFUNCTION
+PREHOOK: query: select *, counter(key) from src limit 20
+PREHOOK: type: QUERY
+PREHOOK: Input: default@src
+#### A masked pattern was here ####
+POSTHOOK: query: select *, counter(key) from src limit 20
+POSTHOOK: type: QUERY
+POSTHOOK: Input: default@src
+#### A masked pattern was here ####
+238	val_238	1
+86	val_86	2
+311	val_311	3
+27	val_27	4
+165	val_165	5
+409	val_409	6
+255	val_255	7
+278	val_278	8
+98	val_98	9
+484	val_484	10
+265	val_265	11
+193	val_193	12
+401	val_401	13
+150	val_150	14
+273	val_273	15
+224	val_224	16
+369	val_369	17
+66	val_66	18
+128	val_128	19
+213	val_213	20



Mime
View raw message