Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HOTFIX] Fix Hadoop-1 build caused by #5792. #6619

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -255,12 +255,12 @@ private[history] class FsHistoryProvider(conf: SparkConf, clock: Clock)
// If this is a legacy directory, then add the directory to the zipStream and add
// each file to that directory.
if (isLegacyLogDirectory(fs.getFileStatus(logPath))) {
val files = fs.listFiles(logPath, false)
val files = fs.listStatus(logPath)
zipStream.putNextEntry(new ZipEntry(attempt.logPath + "/"))
zipStream.closeEntry()
while (files.hasNext) {
val file = files.next().getPath
zipFileToStream(file, attempt.logPath + Path.SEPARATOR + file.getName, zipStream)
files.foreach { file =>
val path = file.getPath
zipFileToStream(path, attempt.logPath + Path.SEPARATOR + path.getName, zipStream)
}
} else {
zipFileToStream(new Path(logDir, attempt.logPath), attempt.logPath, zipStream)
Expand Down