You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by jerryshao <gi...@git.apache.org> on 2016/05/09 07:06:56 UTC

[GitHub] spark pull request: [Minor][SQL] Enhance the exception message if ...

GitHub user jerryshao opened a pull request:

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

    [Minor][SQL] Enhance the exception message if checkpointLocation is not set

    ## What changes were proposed in this pull request?
    
    Enhance the exception message when `checkpointLocation` is not set, previously the message is:
    
    ```
    java.util.NoSuchElementException: None.get
      at scala.None$.get(Option.scala:347)
      at scala.None$.get(Option.scala:345)
      at org.apache.spark.sql.DataFrameWriter$$anonfun$8.apply(DataFrameWriter.scala:338)
      at org.apache.spark.sql.DataFrameWriter$$anonfun$8.apply(DataFrameWriter.scala:338)
      at scala.collection.MapLike$class.getOrElse(MapLike.scala:128)
      at scala.collection.AbstractMap.getOrElse(Map.scala:59)
      at org.apache.spark.sql.DataFrameWriter.startStream(DataFrameWriter.scala:337)
      at org.apache.spark.sql.DataFrameWriter.startStream(DataFrameWriter.scala:277)
      ... 48 elided
    ```
    
    This is not so meaningful, so changing to make it more specific.
    
    
    ## How was this patch tested?
    
    Local verified.


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

    $ git pull https://github.com/jerryshao/apache-spark improve-exception-message

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

    https://github.com/apache/spark/pull/12998.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 #12998
    
----
commit 7d46d4e29b8ca56f3050db279117cff0f94145ab
Author: jerryshao <ss...@hortonworks.com>
Date:   2016-05-09T07:02:04Z

    enhance the exception

----


---
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: [Minor][SQL] Enhance the exception message if ...

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

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


---
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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217790833
  
    **[Test build #58125 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/58125/consoleFull)** for PR 12998 at commit [`7d46d4e`](https://github.com/apache/spark/commit/7d46d4e29b8ca56f3050db279117cff0f94145ab).


---
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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217832754
  
    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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#discussion_r62546067
  
    --- Diff: sql/core/src/main/scala/org/apache/spark/sql/DataFrameWriter.scala ---
    @@ -334,9 +334,11 @@ final class DataFrameWriter private[sql](df: DataFrame) {
               partitionColumns = normalizedParCols.getOrElse(Nil))
     
           val queryName = extraOptions.getOrElse("queryName", StreamExecution.nextName)
    -      val checkpointLocation = extraOptions.getOrElse("checkpointLocation",
    -        new Path(df.sparkSession.sessionState.conf.checkpointLocation.get, queryName).toUri.toString
    -      )
    +      val checkpointLocation = extraOptions.get("checkpointLocation")
    +        .orElse { df.sparkSession.sessionState.conf.checkpointLocation
    +            .map(new Path(_, queryName).toUri.toString)
    --- End diff --
    
    I fixed the style here a little


---
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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217832757
  
    Test PASSed.
    Refer to this link for build results (access rights to CI server needed): 
    https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/58132/
    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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217943730
  
    Looks good, merging into master 2.0


---
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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217802631
  
    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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217802635
  
    Test FAILed.
    Refer to this link for build results (access rights to CI server needed): 
    https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/58125/
    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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217816519
  
    **[Test build #58132 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/58132/consoleFull)** for PR 12998 at commit [`9f5160b`](https://github.com/apache/spark/commit/9f5160bd7b2e62ad9c05cc43ba11cd5edcf1c6fc).


---
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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217802483
  
    **[Test build #58125 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/58125/consoleFull)** for PR 12998 at commit [`7d46d4e`](https://github.com/apache/spark/commit/7d46d4e29b8ca56f3050db279117cff0f94145ab).
     * 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: [Minor][SQL] Enhance the exception message if ...

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

    https://github.com/apache/spark/pull/12998#issuecomment-217832577
  
    **[Test build #58132 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/58132/consoleFull)** for PR 12998 at commit [`9f5160b`](https://github.com/apache/spark/commit/9f5160bd7b2e62ad9c05cc43ba11cd5edcf1c6fc).
     * 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