You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by yhuai <gi...@git.apache.org> on 2015/06/02 01:54:48 UTC

[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

GitHub user yhuai opened a pull request:

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

    [SPARK-8020] Spark SQL in spark-defaults.conf make metadataHive get constructed too early

    https://issues.apache.org/jira/browse/SPARK-8020

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

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

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

    https://github.com/apache/spark/pull/6563.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 #6563
    
----
commit 0398f5b1daba4ffe951e7f5b37ca803f00a8413d
Author: Yin Huai <yh...@databricks.com>
Date:   2015-06-01T23:49:47Z

    First populate the SQLConf and then construct executionHive and metadataHive.

----


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by jeanlyn <gi...@git.apache.org>.
Github user jeanlyn commented on a diff in the pull request:

    https://github.com/apache/spark/pull/6563#discussion_r31490129
  
    --- Diff: sql/hive/src/test/scala/org/apache/spark/sql/hive/client/VersionsSuite.scala ---
    @@ -37,6 +38,48 @@ class VersionsSuite extends SparkFunSuite with Logging {
           "hive.metastore.warehouse.dir" -> warehousePath.toString)
       }
     
    +  test("SPARK-8020: successfully create a HiveContext with metastore settings in Spark conf.") {
    +    val sparkConf =
    +      new SparkConf() {
    +        // We are not really clone it. We need to keep the custom getAll.
    +        override def clone: SparkConf = this
    +
    +        override def getAll: Array[(String, String)] = {
    +          val allSettings = super.getAll
    +          val metastoreVersion = get("spark.sql.hive.metastore.version")
    +          val metastoreJars = get("spark.sql.hive.metastore.jars")
    +
    +          val others = allSettings.filterNot { case (key, _) =>
    +            key == "spark.sql.hive.metastore.version" || key == "spark.sql.hive.metastore.jars"
    +          }
    +
    +          // Put metastore.version to the first one. It is needed to trigger the exception
    +          // caused by SPARK-8020. Other problems triggered by SPARK-8020
    +          // (e.g. using Hive 0.13.1's metastore client to connect to the a 0.12 metastore)
    +          // are not easy to test.
    +          Array(
    +            ("spark.sql.hive.metastore.version" -> metastoreVersion),
    +            ("spark.sql.hive.metastore.jars" -> metastoreJars)) ++ others
    +        }
    +      }
    +    sparkConf
    +      .set("spark.sql.hive.metastore.version", "12")
    --- End diff --
    
    Does `12` equate to `0.12.0` or `1.2`?


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107772053
  
    Merged build finished. Test PASSed.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107759488
  
      [Test build #33936 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/33936/consoleFull) for   PR 6563 at commit [`4e5addc`](https://github.com/apache/spark/commit/4e5addc271973137271c27f50621b5d5cb94f7c8).


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107749490
  
      [Test build #33930 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/33930/consoleFull) for   PR 6563 at commit [`0398f5b`](https://github.com/apache/spark/commit/0398f5b1daba4ffe951e7f5b37ca803f00a8413d).


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by marmbrus <gi...@git.apache.org>.
Github user marmbrus commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107749358
  
    LGTM


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

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


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107756900
  
      [Test build #33935 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/33935/consoleFull) for   PR 6563 at commit [`bf766c6`](https://github.com/apache/spark/commit/bf766c67186197cb577a79304b5ce0b4b9d41c8b).


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107757688
  
      [Test build #33935 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/33935/consoleFull) for   PR 6563 at commit [`bf766c6`](https://github.com/apache/spark/commit/bf766c67186197cb577a79304b5ce0b4b9d41c8b).
     * This patch **fails Scala style tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107772047
  
      [Test build #33930 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/33930/consoleFull) for   PR 6563 at commit [`0398f5b`](https://github.com/apache/spark/commit/0398f5b1daba4ffe951e7f5b37ca803f00a8413d).
     * This patch **passes all tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107756233
  
    Merged build started.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107758757
  
     Merged build triggered.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by yhuai <gi...@git.apache.org>.
Github user yhuai commented on a diff in the pull request:

    https://github.com/apache/spark/pull/6563#discussion_r31490284
  
    --- Diff: sql/hive/src/test/scala/org/apache/spark/sql/hive/client/VersionsSuite.scala ---
    @@ -37,6 +38,48 @@ class VersionsSuite extends SparkFunSuite with Logging {
           "hive.metastore.warehouse.dir" -> warehousePath.toString)
       }
     
    +  test("SPARK-8020: successfully create a HiveContext with metastore settings in Spark conf.") {
    +    val sparkConf =
    +      new SparkConf() {
    +        // We are not really clone it. We need to keep the custom getAll.
    +        override def clone: SparkConf = this
    +
    +        override def getAll: Array[(String, String)] = {
    +          val allSettings = super.getAll
    +          val metastoreVersion = get("spark.sql.hive.metastore.version")
    +          val metastoreJars = get("spark.sql.hive.metastore.jars")
    +
    +          val others = allSettings.filterNot { case (key, _) =>
    +            key == "spark.sql.hive.metastore.version" || key == "spark.sql.hive.metastore.jars"
    +          }
    +
    +          // Put metastore.version to the first one. It is needed to trigger the exception
    +          // caused by SPARK-8020. Other problems triggered by SPARK-8020
    +          // (e.g. using Hive 0.13.1's metastore client to connect to the a 0.12 metastore)
    +          // are not easy to test.
    +          Array(
    +            ("spark.sql.hive.metastore.version" -> metastoreVersion),
    +            ("spark.sql.hive.metastore.jars" -> metastoreJars)) ++ others
    +        }
    +      }
    +    sparkConf
    +      .set("spark.sql.hive.metastore.version", "12")
    --- End diff --
    
    Yeah (https://github.com/apache/spark/blob/master/sql/hive/src/main/scala/org/apache/spark/sql/hive/client/IsolatedClientLoader.scala#L49). 


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107772405
  
    Merged build finished. Test FAILed.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107772398
  
      [Test build #33936 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/33936/consoleFull) for   PR 6563 at commit [`4e5addc`](https://github.com/apache/spark/commit/4e5addc271973137271c27f50621b5d5cb94f7c8).
     * This patch **fails Spark unit tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107758769
  
    Merged build started.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107749374
  
     Merged build triggered.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107757689
  
    Merged build finished. Test FAILed.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107756201
  
     Merged build triggered.


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by yhuai <gi...@git.apache.org>.
Github user yhuai commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107749137
  
    cc @marmbrus 


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

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


[GitHub] spark pull request: [SPARK-8020] Spark SQL in spark-defaults.conf ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the pull request:

    https://github.com/apache/spark/pull/6563#issuecomment-107749391
  
    Merged build started.


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

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