From e26aa7fc3eac04a50902ccb00fe6e79338356ace Mon Sep 17 00:00:00 2001 From: root Date: Thu, 20 Oct 2022 05:52:03 +0000 Subject: [PATCH 1/2] added comments --- src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java b/src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java index 9f70f61..419fff6 100644 --- a/src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java +++ b/src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java @@ -10,9 +10,7 @@ * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ + * See the License for the specific language governing permissions. package com.waratek.spiracle.sql.util; import java.io.IOException; From b4ce698cd2002f419bdaaadb6d75d2cee761f73d Mon Sep 17 00:00:00 2001 From: himank-k2 Date: Thu, 20 Oct 2022 05:55:22 +0000 Subject: [PATCH 2/2] added comments --- .../waratek/spiracle/sql/util/UpdateUtil.java | 31 ------------------- 1 file changed, 31 deletions(-) diff --git a/src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java b/src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java index 419fff6..20a7719 100644 --- a/src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java +++ b/src/main/java/com/waratek/spiracle/sql/util/UpdateUtil.java @@ -79,37 +79,6 @@ public static void executeUpdate(String sql, ServletContext application, HttpSer } while((e = e.getNextException()) != null) { out.println(e.getMessage() + "
"); - } - } finally { - try { - if(stmt != null) { - logger.info("Closing PreparedStatement " + stmt); - stmt.close(); - logger.info("Closed PreparedStatement " + stmt); - } - } catch (SQLException stmtCloseException) { - if(logger.isDebugEnabled()) { - logger.debug(stmtCloseException.getMessage(), stmtCloseException); - } else { - logger.error(stmtCloseException); - } - } - try { - if(con != null) { - logger.info("Closing Connection " + con); - con.close(); - logger.info("Closed Connection " + con); - } - } catch (SQLException conCloseException) { - if(logger.isDebugEnabled()) { - logger.debug(conCloseException.getMessage(), conCloseException); - } else { - logger.error(conCloseException); - } - } - - out.println(""); - TagUtil.printPageFooter(out); out.close(); } }