diff --git a/fe/fe-core/src/main/java/org/apache/doris/datasource/iceberg/IcebergMetadataOps.java b/fe/fe-core/src/main/java/org/apache/doris/datasource/iceberg/IcebergMetadataOps.java index 440a671afe58f1..da61b2ac1ab7fe 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/datasource/iceberg/IcebergMetadataOps.java +++ b/fe/fe-core/src/main/java/org/apache/doris/datasource/iceberg/IcebergMetadataOps.java @@ -104,7 +104,7 @@ public List listDatabaseNames() { .map(n -> n.level(n.length() - 1)) .collect(Collectors.toList())); } catch (Exception e) { - throw new RuntimeException("Failed to list database names, error message is: " + e.getMessage()); + throw new RuntimeException("Failed to list database names, error message is:" + e.getMessage(), e); } } @@ -125,7 +125,7 @@ public void createDb(CreateDbStmt stmt) throws DdlException { }); } catch (Exception e) { throw new DdlException("Failed to create database: " - + stmt.getFullDbName() + " ,error message is: " + e.getMessage()); + + stmt.getFullDbName() + ", error message is:" + e.getMessage(), e); } } @@ -161,7 +161,7 @@ public void dropDb(DropDbStmt stmt) throws DdlException { }); } catch (Exception e) { throw new DdlException( - "Failed to drop database: " + stmt.getDbName() + ", error message is: " + e.getMessage(), e); + "Failed to drop database: " + stmt.getDbName() + ", error message is:" + e.getMessage(), e); } } @@ -184,7 +184,8 @@ public boolean createTable(CreateTableStmt stmt) throws UserException { try { preExecutionAuthenticator.execute(() -> performCreateTable(stmt)); } catch (Exception e) { - throw new DdlException("Failed to create table: " + stmt.getTableName() + " ,error message is:", e); + throw new DdlException( + "Failed to create table: " + stmt.getTableName() + ", error message is:" + e.getMessage(), e); } return false; } @@ -228,7 +229,8 @@ public void dropTable(DropTableStmt stmt) throws DdlException { return null; }); } catch (Exception e) { - throw new DdlException("Failed to drop table: " + stmt.getTableName() + " ,error message is:", e); + throw new DdlException( + "Failed to drop table: " + stmt.getTableName() + ", error message is:" + e.getMessage(), e); } }