This is an automated email from the ASF dual-hosted git repository. ahuber pushed a commit to branch v3 in repository https://gitbox.apache.org/repos/asf/causeway.git
commit e055161ed189aed4ad981c2d99a8353f19c3bcf4 Merge: 5f1df626d7 ccdf06d5fc Author: andi-huber <[email protected]> AuthorDate: Fri Aug 9 15:08:20 2024 +0200 Merge remote-tracking branch 'origin/master' into v3 .../org/apache/causeway/commons/io/DataSource.java | 147 ++++++++++++++++++++- .../org/apache/causeway/commons/io/ZipUtils.java | 15 +-- .../apache/causeway/commons/io/DataSourceTest.java | 86 ++++++++++++ 3 files changed, 233 insertions(+), 15 deletions(-) diff --cc commons/src/main/java/org/apache/causeway/commons/io/ZipUtils.java index d2e1a3c2a5,b7c940741f..07557366fc --- a/commons/src/main/java/org/apache/causeway/commons/io/ZipUtils.java +++ b/commons/src/main/java/org/apache/causeway/commons/io/ZipUtils.java @@@ -141,11 -140,9 +140,9 @@@ public class ZipUtils final @NonNull ZipOptions zipOptions) { val zipEntryDataSources = _Lists.<ZipEntryDataSource>newArrayList(); - - var tempFile = File.createTempFile("causeway", "zip-utils"); - try { - zippedSource.tryReadAndWrite(DataSink.ofFile(tempFile), 4096); - try (FileSystem fs = FileSystems.newFileSystem(tempFile.toPath())) { - ++ + zippedSource.consumeAsFile(zipFile->{ - try (FileSystem fs = FileSystems.newFileSystem(zipFile.toPath(), null)) { ++ try (FileSystem fs = FileSystems.newFileSystem(zipFile.toPath())) { try (Stream<Path> entries = Files.walk(fs.getPath("/"))) { final List<Path> filesInZip = entries.filter(Files::isRegularFile).collect(Collectors.toList()); for(Path path : filesInZip) {
