From 2f43bae7e293ad020582409c8b6742e4ca027ad7 Mon Sep 17 00:00:00 2001 From: Marc Cenac Date: Fri, 17 Oct 2025 16:17:06 -0500 Subject: [PATCH] Rethrow StorageException as IOException --- .../src/main/java/io/trino/filesystem/gcs/GcsOutputStream.java | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/trino-filesystem-gcs/src/main/java/io/trino/filesystem/gcs/GcsOutputStream.java b/lib/trino-filesystem-gcs/src/main/java/io/trino/filesystem/gcs/GcsOutputStream.java index a931e24cf849..d13267966148 100644 --- a/lib/trino-filesystem-gcs/src/main/java/io/trino/filesystem/gcs/GcsOutputStream.java +++ b/lib/trino-filesystem-gcs/src/main/java/io/trino/filesystem/gcs/GcsOutputStream.java @@ -141,6 +141,7 @@ public void close() if (e.getCode() == HTTP_PRECON_FAILED) { throw new FileAlreadyExistsException(location.toString()); } + throw new IOException(e); } catch (IOException e) { throw new IOException("Error closing file: " + location, e);