Github user tdas commented on a diff in the pull request:
https://github.com/apache/spark/pull/20097#discussion_r159980348
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/streaming/DataStreamReader.scala
---
@@ -166,19 +167,31 @@ final class DataStreamReader
private[sql](sparkSession: SparkSession) extends Lo
userSpecifiedSchema = userSpecifiedSchema,
className = source,
options = extraOptions.toMap)
+ val v1Relation = ds match {
+ case _: StreamSourceProvider => Some(StreamingRelation(v1DataSource))
+ case _ => None
+ }
ds match {
+ case s: MicroBatchReadSupport =>
+ val tempReader = s.createMicroBatchReader(
+ java.util.Optional.ofNullable(userSpecifiedSchema.orNull),
--- End diff --
Please import Optional, the full path is used in multiple places.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]