[GitHub] spark pull request #14497: [SPARK-16901] Hive settings in hive-site.xml may ...

2016-08-05 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/spark/pull/14497


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #14497: [SPARK-16901] Hive settings in hive-site.xml may ...

2016-08-05 Thread yhuai
Github user yhuai commented on a diff in the pull request:

https://github.com/apache/spark/pull/14497#discussion_r73723916
  
--- Diff: 
sql/hive/src/test/scala/org/apache/spark/sql/hive/HiveSparkSubmitSuite.scala ---
@@ -253,6 +253,47 @@ class HiveSparkSubmitSuite
 runSparkSubmit(args)
   }
 
+  test("SPARK-16901: set javax.jdo.option.ConnectionURL") {
+// In this test, we set hive.metastore.warehouse.dir in hive-site.xml 
but
+// not set spark.sql.warehouse.dir. So, the warehouse dir should be
+// the value of hive.metastore.warehouse.dir. Also, the value of
+// spark.sql.warehouse.dir should be set to the value of 
hive.metastore.warehouse.dir.
--- End diff --

sorry. Bad comment.


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #14497: [SPARK-16901] Hive settings in hive-site.xml may ...

2016-08-04 Thread yhuai
GitHub user yhuai opened a pull request:

https://github.com/apache/spark/pull/14497

[SPARK-16901] Hive settings in hive-site.xml may be overridden by Hive's 
default values

## What changes were proposed in this pull request?
When we create the HiveConf for metastore client, we use a Hadoop Conf as 
the base, which may contain Hive settings in hive-site.xml 
(https://github.com/apache/spark/blob/master/sql/core/src/main/scala/org/apache/spark/sql/internal/SharedState.scala#L49).
 However, HiveConf's initialize function basically ignores the base Hadoop Conf 
and always its default values (i.e. settings with non-null default values) as 
the base 
(https://github.com/apache/hive/blob/release-1.2.1/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L2687).
 So, even a user put javax.jdo.option.ConnectionURL in hive-site.xml, it is not 
used and Hive will use its default, which is 
jdbc:derby:;databaseName=metastore_db;create=true.

This issue only shows up when `spark.sql.hive.metastore.jars` is not set to 
builtin.


## How was this patch tested?
New test in HiveSparkSubmitSuite.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/yhuai/spark SPARK-16901

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/spark/pull/14497.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 #14497


commit 6c6d197ccbfb22daac4f6710b8b86411a9d99483
Author: Yin Huai 
Date:   2016-08-04T20:32:58Z

[SPARK-16901] Hive settings in hive-site.xml may be overridden by Hive's 
default values




---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org