Github user pwendell commented on a diff in the pull request:

    https://github.com/apache/spark/pull/3389#discussion_r20682042
  
    --- Diff: 
streaming/src/main/scala/org/apache/spark/streaming/dstream/FileInputDStream.scala
 ---
    @@ -17,18 +17,50 @@
     
     package org.apache.spark.streaming.dstream
     
    -import java.io.{ObjectInputStream, IOException}
    -import scala.collection.mutable.{HashSet, HashMap}
    +import java.io.{IOException, ObjectInputStream}
    +
    +import scala.Some
    +import scala.collection.mutable
    +import scala.collection.mutable.HashMap
     import scala.reflect.ClassTag
    +
     import org.apache.hadoop.fs.{FileSystem, Path, PathFilter}
    -import org.apache.hadoop.conf.Configuration
     import org.apache.hadoop.mapreduce.{InputFormat => NewInputFormat}
    -import org.apache.spark.rdd.RDD
    -import org.apache.spark.rdd.UnionRDD
    -import org.apache.spark.streaming.{StreamingContext, Time}
    +import org.apache.spark.rdd.{RDD, UnionRDD}
    +import org.apache.spark.streaming._
     import org.apache.spark.util.{TimeStampedHashMap, Utils}
     
    -
    +/**
    + * This class represents an input stream that monitors a Hadoop-compatible 
filesystem for new
    + * files and creates a stream out of them. The way it works as follows.
    + *
    + * This class remembers the information about the files selected in past 
batches for
    --- End diff --
    
    This goes right into discussing how to work around file visibility issues 
but it doesn't discuss anything about the basic operation of the class first. 
It might be good to have something first that says:
    
    ```
    At each batch interval, new files are detected and included in that batch. 
In this case "new" means files that became visible to readers during that time 
period. Some extra care is needed to deal with the fact that files may become 
visible after they are created.
    ```


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

Reply via email to