GitHub user wangyum opened a pull request:
https://github.com/apache/spark/pull/16122
[SPARK-18681][SQL] Fix filtering to compatible with partition keys of type
int
## What changes were proposed in this pull request?
Cloudera's Hive default configuration: `hive.metastore.try.direct.sql=true`
and `hive.metastore.integral.jdo.pushdown=false`. It will throw `Filtering is
supported only on partition keys of type string` exception and program exit
after [SPARK-17992](https://issues.apache.org/jira/browse/SPARK-17992). This
fix to catch this exception and return all partitions like previously spark
version.
## How was this patch tested?
It can't reproduce this issue in a similar way to
[HiveClientSuite.scala](https://github.com/apache/spark/blob/master/sql/hive/src/test/scala/org/apache/spark/sql/hive/client/HiveClientSuite.scala).
May be we need a real metastore, So I build code and manual test this fix on
my spark cluster.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/wangyum/spark SPARK-18681
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/16122.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #16122
----
commit f792cb475d0758f663be7f61ad1cd656489f9b72
Author: Yuming Wang <[email protected]>
Date: 2016-12-02T16:29:49Z
Fix filtering to compatible with partition keys of type int
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]