Github user jaceklaskowski commented on a diff in the pull request:
https://github.com/apache/spark/pull/19056#discussion_r135989439
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/socket.scala
---
@@ -130,16 +130,7 @@ class TextSocketSource(host: String, port: Int,
includeTimestamp: Boolean, sqlCo
val rdd = sqlContext.sparkContext.parallelize(rawList).map(
v => InternalRow(UTF8String.fromString(v._1), v._2.getTime()))
--- End diff --
May I ask to replace `v` with `case...` as follows? IMHO That would make
things easier to read.
```
val rdd = sqlContext.sparkContext.
parallelize(rawList).
map { case (v, ts) => InternalRow(UTF8String.fromString(v),
ts.getTime) }
```
---
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]