vanzin commented on a change in pull request #22952: [SPARK-20568][SS] Provide
option to clean up completed files in streaming query
URL: https://github.com/apache/spark/pull/22952#discussion_r339710570
##########
File path:
sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/FileStreamSource.scala
##########
@@ -330,4 +362,77 @@ object FileStreamSource {
def size: Int = map.size()
}
+
+ private[sql] class FileStreamSourceCleaner(
+ fileSystem: FileSystem,
+ sourcePath: Path,
+ baseArchiveFileSystem: Option[FileSystem],
+ baseArchivePath: Option[Path]) extends Logging {
+ assertParameters()
+
+ private def assertParameters(): Unit = {
+ require(baseArchiveFileSystem.isDefined == baseArchivePath.isDefined)
+
+ baseArchiveFileSystem.foreach { fs =>
+ require(fileSystem.getUri == fs.getUri, "Base archive path is located
to the different" +
Review comment:
"Base archive path is located on a different file system than the source
files."
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]