[GitHub] spark pull request #13460: Json dataset

2016-06-01 Thread HyukjinKwon
Github user HyukjinKwon commented on a diff in the pull request:

https://github.com/apache/spark/pull/13460#discussion_r65480667
  
--- Diff: 
sql/core/src/test/scala/org/apache/spark/sql/execution/datasources/json/TestJsonData.scala
 ---
@@ -17,14 +17,15 @@
 
 package org.apache.spark.sql.execution.datasources.json
 
-import org.apache.spark.rdd.RDD
-import org.apache.spark.sql.SparkSession
+import org.apache.spark.sql.{Dataset, SparkSession, SQLContext}
+import org.apache.spark.sql.test.SharedSQLContext
 
-private[json] trait TestJsonData {
-  protected def spark: SparkSession
+private[json] trait TestJsonData extends SharedSQLContext {
+  val importContext = sqlContext
+  import importContext.implicits._
--- End diff --

I guess you want 
[`testImplicits._`](https://github.com/apache/spark/blob/master/sql/core/src/test/scala/org/apache/spark/sql/test/SQLTestUtils.scala#L61-L70)..


---
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 #13460: Json dataset

2016-06-01 Thread HyukjinKwon
Github user HyukjinKwon commented on a diff in the pull request:

https://github.com/apache/spark/pull/13460#discussion_r65480498
  
--- Diff: 
sql/core/src/main/scala/org/apache/spark/sql/DataFrameReader.scala ---
@@ -335,16 +336,32 @@ class DataFrameReader private[sql](sparkSession: 
SparkSession) extends Logging {
* input once to determine the input schema.
*
* @param jsonRDD input RDD with one JSON object per record
-   * @since 1.4.0
+   * @since 1.4.0*
--- End diff --

It seems there is a type here, `*`.


---
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 #13460: Json dataset

2016-06-01 Thread pjfanning
GitHub user pjfanning opened a pull request:

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

Json dataset

## What changes were proposed in this pull request?

[SPARK-15615] add new json function that takes Dataset[String] as input and 
deprecate the existing RDD based functions

## How was this patch tested?

Changed the existing unit tests


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

$ git pull https://github.com/pjfanning/spark json-dataset

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

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


commit f8683a2bba1bd910a39443a90689f794f6c1e6dc
Author: PJ Fanning 
Date:   2016-05-28T12:07:27Z

[SPARK-15615] add json(Dataset[String])

commit 1cc1ffc0594794cbd5d3d8c8916b12ac8ca37416
Author: PJ Fanning 
Date:   2016-05-28T12:07:27Z

[SPARK-15615] add json(Dataset[String])

commit 19525ffd1b8e1a97ee4a2b9d2f664833a9740146
Author: PJ Fanning 
Date:   2016-06-02T03:17:58Z

Merge branch 'json-dataset' of https://github.com/pjfanning/spark into 
json-dataset

Conflicts:
sql/core/src/main/scala/org/apache/spark/sql/DataFrameReader.scala

sql/core/src/test/scala/org/apache/spark/sql/execution/datasources/json/TestJsonData.scala




---
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