Packages

class FileStreamOptions extends Logging

User specified options for file streams.

Linear Supertypes
Logging, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. FileStreamOptions
  2. Logging
  3. AnyRef
  4. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new FileStreamOptions(parameters: Map[String, String])
  2. new FileStreamOptions(parameters: CaseInsensitiveMap[String])

Value Members

  1. val cleanSource: CleanSourceMode.Value

    Defines how to clean up completed files.

    Defines how to clean up completed files. Available options are "archive", "delete", "off".

  2. val fileNameOnly: Boolean

    Whether to check new files based on only the filename instead of on the full path.

    Whether to check new files based on only the filename instead of on the full path.

    With this set to true, the following files would be considered as the same file, because their filenames, "dataset.txt", are the same: - "file:///dataset.txt" - "s3://a/dataset.txt" - "s3n://a/b/dataset.txt" - "s3a://a/b/c/dataset.txt"

  3. val latestFirst: Boolean

    Whether to scan latest files first.

    Whether to scan latest files first. If it's true, when the source finds unprocessed files in a trigger, it will first process the latest files.

  4. val maxFileAgeMs: Long

    Maximum age of a file that can be found in this directory, before it is ignored.

    Maximum age of a file that can be found in this directory, before it is ignored. For the first batch all files will be considered valid. If latestFirst is set to true and maxFilesPerTrigger is set, then this parameter will be ignored, because old files that are valid, and should be processed, may be ignored. Please refer to SPARK-19813 for details.

    The max age is specified with respect to the timestamp of the latest file, and not the timestamp of the current system. That this means if the last file has timestamp 1000, and the current system time is 2000, and max age is 200, the system will purge files older than 800 (rather than 1800) from the internal state.

    Default to a week.

  5. val maxFilesPerTrigger: Option[Int]
  6. val optionMapWithoutPath: Map[String, String]

    Options as specified by the user, in a case-insensitive map, without "path" set.

  7. val sourceArchiveDir: Option[String]

    The archive directory to move completed files.

    The archive directory to move completed files. The option will be only effective when "cleanSource" is set to "archive".

    Note that the completed file will be moved to this archive directory with respecting to its own path.

    For example, if the path of source file is "/a/b/dataset.txt", and the path of archive directory is "/archived/here", file will be moved to "/archived/here/a/b/dataset.txt".