This is an automated email from the ASF dual-hosted git repository.

dsmiley pushed a commit to branch branch_9x
in repository https://gitbox.apache.org/repos/asf/solr.git


The following commit(s) were added to refs/heads/branch_9x by this push:
     new e756ee846fd IOUtils: add back closeQuietly(Closeable) (#3199)
e756ee846fd is described below

commit e756ee846fd931355384b40198e049f174b1a6b7
Author: David Smiley <[email protected]>
AuthorDate: Thu Feb 20 15:42:52 2025 -0500

    IOUtils: add back closeQuietly(Closeable) (#3199)
    
    To retain compatibility within 9x.
---
 solr/solrj/src/java/org/apache/solr/common/util/IOUtils.java | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/solr/solrj/src/java/org/apache/solr/common/util/IOUtils.java 
b/solr/solrj/src/java/org/apache/solr/common/util/IOUtils.java
index b91553a1813..384aa4bcbad 100644
--- a/solr/solrj/src/java/org/apache/solr/common/util/IOUtils.java
+++ b/solr/solrj/src/java/org/apache/solr/common/util/IOUtils.java
@@ -16,6 +16,7 @@
  */
 package org.apache.solr.common.util;
 
+import java.io.Closeable;
 import java.lang.invoke.MethodHandles;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -32,4 +33,8 @@ public class IOUtils {
       log.error("Error while closing", e);
     }
   }
+
+  public static void closeQuietly(Closeable closeable) {
+    closeQuietly((AutoCloseable) closeable);
+  }
 }

Reply via email to