Skip to content

Commit

Permalink
Rebase onto 0.8.0 and release
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryan Murray committed Apr 26, 2021
1 parent 99cdec7 commit 4fddd56
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,8 @@ object DeltaFileOperations extends DeltaLogging {
val dirsAndFiles = spark.sparkContext.parallelize(subDirs).mapPartitions { dirs =>
val logStore = LogStore(SparkEnv.get.conf, hadoopConf.value.value)
val logFileHandler = LogFileMetaParser(SparkEnv.get.conf, hadoopConf.value.value, logStore)
listUsingLogStore(logFileHandler, dirs, recurse = false, hiddenFileNameFilter, listAsDirectories)
listUsingLogStore(logFileHandler, dirs, recurse = false, hiddenFileNameFilter,
listAsDirectories)
}.repartition(listParallelism) // Initial list of subDirs may be small

val allDirsAndFiles = dirsAndFiles.mapPartitions { firstLevelDirsAndFiles =>
Expand Down Expand Up @@ -265,8 +266,11 @@ object DeltaFileOperations extends DeltaLogging {
dirs: Seq[String],
recursive: Boolean = true,
fileFilter: String => Boolean = defaultHiddenFileFilter): Iterator[SerializableFileStatus] = {
val logStore = LogStore(SparkEnv.get.conf, spark.sessionState.newHadoopConf)
listUsingLogStore(logStore, dirs.toIterator, recurse = recursive, fileFilter)
val hadoopConfig = spark.sessionState.newHadoopConf
val sparkConf = SparkEnv.get.conf
val logStore = LogStore(sparkConf, hadoopConfig)
val logFileHandler = LogFileMetaParser(sparkConf, hadoopConfig, logStore)
listUsingLogStore(logFileHandler, dirs.toIterator, recurse = recursive, fileFilter)
}

/**
Expand All @@ -281,10 +285,11 @@ object DeltaFileOperations extends DeltaLogging {
recursive: Boolean = true,
fileFilter: String => Boolean = defaultHiddenFileFilter): Iterator[SerializableFileStatus] = {
val hadoopConfig = spark.sessionState.newHadoopConf
val logStore = LogStore(SparkEnv.get.conf, hadoopConfig)
val sparkConf = SparkEnv.get.conf
val logStore = LogStore(sparkConf, hadoopConfig)
val logFileHandler = LogFileMetaParser(sparkConf, hadoopConfig, logStore)
val listDirs = getAllTopComponents(new Path(listFilename), new Path(topDir))
listUsingLogStore(logStore, listDirs.toIterator, recurse = recursive, fileFilter,
listUsingLogStore(logFileHandler, listDirs.toIterator, recurse = recursive, fileFilter,
listAsDirectories = false)
}

Expand Down
2 changes: 1 addition & 1 deletion version.sbt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version in ThisBuild := "0.9.0-nessie-SNAPSHOT"
version in ThisBuild := "0.8.0-nessie"

0 comments on commit 4fddd56

Please sign in to comment.