Repository: incubator-hawq
Updated Branches:
  refs/heads/master 0f61e8597 -> e150dc4e3


HAWQ-779. PXF Fix filter test failures


Project: http://git-wip-us.apache.org/repos/asf/incubator-hawq/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-hawq/commit/e150dc4e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-hawq/tree/e150dc4e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-hawq/diff/e150dc4e

Branch: refs/heads/master
Commit: e150dc4e346bf471687e32c32f37c66896d302ec
Parents: 0f61e85
Author: Shivram Mani <[email protected]>
Authored: Thu Jul 7 15:04:31 2016 -0700
Committer: Shivram Mani <[email protected]>
Committed: Thu Jul 7 15:04:31 2016 -0700

----------------------------------------------------------------------
 .../org/apache/hawq/pxf/plugins/hbase/HBaseFilterBuilder.java     | 2 +-
 .../hawq/pxf/plugins/hive/utilities/EnumHiveToHawqType.java       | 2 +-
 .../java/org/apache/hawq/pxf/plugins/json/JsonRecordReader.java   | 2 +-
 .../hawq/pxf/plugins/json/parser/PartitionedJsonParser.java       | 3 +--
 src/backend/access/external/test/pxffilters_test.c                | 3 ++-
 5 files changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/e150dc4e/pxf/pxf-hbase/src/main/java/org/apache/hawq/pxf/plugins/hbase/HBaseFilterBuilder.java
----------------------------------------------------------------------
diff --git 
a/pxf/pxf-hbase/src/main/java/org/apache/hawq/pxf/plugins/hbase/HBaseFilterBuilder.java
 
b/pxf/pxf-hbase/src/main/java/org/apache/hawq/pxf/plugins/hbase/HBaseFilterBuilder.java
index 8dc932c..573fb81 100644
--- 
a/pxf/pxf-hbase/src/main/java/org/apache/hawq/pxf/plugins/hbase/HBaseFilterBuilder.java
+++ 
b/pxf/pxf-hbase/src/main/java/org/apache/hawq/pxf/plugins/hbase/HBaseFilterBuilder.java
@@ -250,7 +250,7 @@ public class HBaseFilterBuilder implements 
FilterParser.FilterBuilder {
      * Currently, multiple calls to this function might change
      * previous assignments.
      */
-    private void storeStartEndKeys(FilterParser.Operation op, Object data) {
+    private void storeStartEndKeys(FilterParser.Operation op, Object data) 
throws Exception{
         String key = (String) data;
 
         // Adding a zero byte to endkey, makes it inclusive

http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/e150dc4e/pxf/pxf-hive/src/main/java/org/apache/hawq/pxf/plugins/hive/utilities/EnumHiveToHawqType.java
----------------------------------------------------------------------
diff --git 
a/pxf/pxf-hive/src/main/java/org/apache/hawq/pxf/plugins/hive/utilities/EnumHiveToHawqType.java
 
b/pxf/pxf-hive/src/main/java/org/apache/hawq/pxf/plugins/hive/utilities/EnumHiveToHawqType.java
index a747bd5..df376d0 100644
--- 
a/pxf/pxf-hive/src/main/java/org/apache/hawq/pxf/plugins/hive/utilities/EnumHiveToHawqType.java
+++ 
b/pxf/pxf-hive/src/main/java/org/apache/hawq/pxf/plugins/hive/utilities/EnumHiveToHawqType.java
@@ -89,7 +89,7 @@ public enum EnumHiveToHawqType {
     /**
      * Returns Hive to HAWQ type mapping entry for given Hive type 
      * 
-     * @param hiveType full Hive type with modifiers, for example - 
decimal(10, 0), char(5), binary, array<string>, map<string,float> etc
+     * @param hiveType full Hive type with modifiers, for example - 
decimal(10, 0), char(5), binary, array&lt;string&gt;, map&lt;string,float&gt; 
etc
      * @return corresponding Hive to HAWQ type mapping entry
      * @throws UnsupportedTypeException if there is no corresponding HAWQ type
      */

http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/e150dc4e/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/JsonRecordReader.java
----------------------------------------------------------------------
diff --git 
a/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/JsonRecordReader.java
 
b/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/JsonRecordReader.java
index 26d4c82..fe1d2f1 100644
--- 
a/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/JsonRecordReader.java
+++ 
b/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/JsonRecordReader.java
@@ -67,7 +67,7 @@ public class JsonRecordReader implements 
RecordReader<LongWritable, Text> {
         *            Hadoop context
         * @param split
         *            HDFS split to start the reading from
-        * @throws IOException
+        * @throws IOException IOException
         */
        public JsonRecordReader(JobConf conf, FileSplit split) throws 
IOException {
 

http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/e150dc4e/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/parser/PartitionedJsonParser.java
----------------------------------------------------------------------
diff --git 
a/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/parser/PartitionedJsonParser.java
 
b/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/parser/PartitionedJsonParser.java
index 71ad449..71ed81c 100644
--- 
a/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/parser/PartitionedJsonParser.java
+++ 
b/pxf/pxf-json/src/main/java/org/apache/hawq/pxf/plugins/json/parser/PartitionedJsonParser.java
@@ -34,7 +34,6 @@ import 
org.apache.hawq.pxf.plugins.json.parser.JsonLexer.JsonLexerState;
  * stream (which is assumed to be positioned at any arbitrary position inside 
some JSON text) until it finds the first
  * JSON begin-object "{". From this point on it will keep reading JSON objects 
until it finds one containing a member
  * string that the user supplies.
- * <p/>
  * It is not recommended to use this with JSON text where individual JSON 
objects that can be large (MB's or larger).
  */
 public class PartitionedJsonParser {
@@ -88,7 +87,7 @@ public class PartitionedJsonParser {
         *            Indicates the member name used to determine the 
encapsulating object to return.
         * @return Returns next json object that contains a member attribute 
with name: memberName. Returns null if no such
         *         object is found or the end of the stream is reached.
-        * @throws IOException
+        * @throws IOException IOException
         */
        public String nextObjectContainingMember(String memberName) throws 
IOException {
 

http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/e150dc4e/src/backend/access/external/test/pxffilters_test.c
----------------------------------------------------------------------
diff --git a/src/backend/access/external/test/pxffilters_test.c 
b/src/backend/access/external/test/pxffilters_test.c
index a5b3fb0..a694ccf 100644
--- a/src/backend/access/external/test/pxffilters_test.c
+++ b/src/backend/access/external/test/pxffilters_test.c
@@ -42,6 +42,7 @@ test__supported_filter_type(void **state)
                CHAROID,
                BYTEAOID,
                BOOLOID,
+        DATEOID,
                CIRCLEOID /* unsupported type */
        };
 
@@ -61,7 +62,7 @@ test__supported_filter_type(void **state)
 
        /* go over pxf_supported_types array */
        int nargs = sizeof(pxf_supported_types) / sizeof(Oid);
-       assert_int_equal(nargs, 12);
+       assert_int_equal(nargs, (array_size-1));
        for (i = 0; i < nargs; ++i)
        {
                assert_true(supported_filter_type(pxf_supported_types[i]));

Reply via email to