[ 
https://issues.apache.org/jira/browse/HADOOP-19542?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17944846#comment-17944846
 ] 

ASF GitHub Bot commented on HADOOP-19542:
-----------------------------------------

steveloughran commented on code in PR #7616:
URL: https://github.com/apache/hadoop/pull/7616#discussion_r2045532243


##########
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/statistics/StreamStatisticNames.java:
##########
@@ -104,6 +104,13 @@ public final class StreamStatisticNames {
    */
   public static final String STREAM_READ_ANALYTICS_OPENED = 
"stream_read_analytics_opened";
 
+  /**
+   * Total count of times object stream factory was closed

Review Comment:
   nit, add .



##########
hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/impl/streams/AnalyticsStreamFactory.java:
##########
@@ -95,6 +96,13 @@ public StreamFactoryRequirements factoryRequirements() {
             StreamFactoryRequirements.Requirements.ExpectUnauditedGetRequests);
   }
 
+  @Override
+  protected void serviceStop() throws Exception {
+    super.serviceStop();
+    this.s3SeekableInputStreamFactory.close();

Review Comment:
   do these before calling the superclass. I think that's actually a no-op, but 
good to unwind in order



##########
hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/impl/streams/ObjectInputStreamFactory.java:
##########
@@ -20,6 +20,7 @@
 
 import java.io.IOException;
 
+import org.apache.hadoop.fs.s3a.Statistic;

Review Comment:
   ordering





> S3A Analytics-Accelerator: AAL stream factory not being closed
> --------------------------------------------------------------
>
>                 Key: HADOOP-19542
>                 URL: https://issues.apache.org/jira/browse/HADOOP-19542
>             Project: Hadoop Common
>          Issue Type: Sub-task
>          Components: fs/s3
>    Affects Versions: 3.4.2
>            Reporter: Ahmar Suhail
>            Assignee: Ahmar Suhail
>            Priority: Blocker
>              Labels: pull-request-available
>
> When the Factory service is stopped, we're currently missing the code to 
> close the factory. My miss, this got lost in the move to the new factory 
> code. 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: common-issues-h...@hadoop.apache.org

Reply via email to