You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ozone.apache.org by sa...@apache.org on 2020/03/05 03:40:19 UTC

[hadoop-ozone] 01/01: Revert "HDDS-3041. Memory leak of s3g (#611)"

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

sammichen pushed a commit to branch revert-611-s3g-memory-leak
in repository https://gitbox.apache.org/repos/asf/hadoop-ozone.git

commit 023553e2de7711b9d00c9a14bd88e3f5bc1770c8
Author: Sammi Chen <sa...@apache.org>
AuthorDate: Thu Mar 5 11:40:07 2020 +0800

    Revert "HDDS-3041. Memory leak of s3g (#611)"
    
    This reverts commit 51217d64540ee6786d5be0c12546a2988fef2179.
---
 .../java/org/apache/hadoop/ozone/s3/OzoneClientProducer.java   | 10 +---------
 pom.xml                                                        |  2 +-
 2 files changed, 2 insertions(+), 10 deletions(-)

diff --git a/hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/OzoneClientProducer.java b/hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/OzoneClientProducer.java
index 414d85c..45e58d9 100644
--- a/hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/OzoneClientProducer.java
+++ b/hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/OzoneClientProducer.java
@@ -17,7 +17,6 @@
  */
 package org.apache.hadoop.ozone.s3;
 
-import javax.annotation.PreDestroy;
 import javax.enterprise.context.RequestScoped;
 import javax.enterprise.inject.Produces;
 import javax.inject.Inject;
@@ -48,7 +47,6 @@ public class OzoneClientProducer {
 
   private final static Logger LOG =
       LoggerFactory.getLogger(OzoneClientProducer.class);
-  private OzoneClient client;
 
   @Inject
   private SignatureProcessor v4RequestParser;
@@ -65,13 +63,7 @@ public class OzoneClientProducer {
 
   @Produces
   public OzoneClient createClient() throws IOException {
-    client = getClient(ozoneConfiguration);
-    return client;
-  }
-  
-  @PreDestroy
-  public void destory() throws IOException {
-    client.close();
+    return getClient(ozoneConfiguration);
   }
 
   private OzoneClient getClient(OzoneConfiguration config) throws IOException {
diff --git a/pom.xml b/pom.xml
index 233e22d..4ffa52a 100644
--- a/pom.xml
+++ b/pom.xml
@@ -78,7 +78,7 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xs
     <declared.ozone.version>${ozone.version}</declared.ozone.version>
 
     <!-- Apache Ratis version -->
-    <ratis.version>0.6.0-a320ae0-SNAPSHOT</ratis.version>
+    <ratis.version>0.5.0</ratis.version>
     <distMgmtSnapshotsId>apache.snapshots.https</distMgmtSnapshotsId>
     <distMgmtSnapshotsName>Apache Development Snapshot Repository</distMgmtSnapshotsName>
     <distMgmtSnapshotsUrl>https://repository.apache.org/content/repositories/snapshots</distMgmtSnapshotsUrl>


---------------------------------------------------------------------
To unsubscribe, e-mail: ozone-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: ozone-commits-help@hadoop.apache.org