Skip to content

Commit

Permalink
concurrency issue unzipping file, need to catch FileSystemAlreadyExis…
Browse files Browse the repository at this point in the history
…tsException

Signed-off-by: Olivier Lamy <olamy@apache.org>
  • Loading branch information
olamy committed Oct 22, 2024
1 parent afdbad5 commit 568cb27
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
import java.nio.file.CopyOption;
import java.nio.file.FileAlreadyExistsException;
import java.nio.file.FileSystem;
import java.nio.file.FileSystemAlreadyExistsException;
import java.nio.file.FileSystems;
import java.nio.file.Files;
import java.nio.file.Path;
Expand Down Expand Up @@ -261,7 +262,7 @@ public static void unzip(Path archive, Path outputDir) throws IOException
}
}
}
catch (FileAlreadyExistsException e)
catch (FileAlreadyExistsException | FileSystemAlreadyExistsException e)
{
LOG.warn("ignore FileAlreadyExistsException: archiveURI {}, outputDir {}", archiveURI, outputDir);
}
Expand Down

0 comments on commit 568cb27

Please sign in to comment.