[ https://issues.apache.org/jira/browse/BEAM-6018?focusedWorklogId=164412&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-164412 ]
ASF GitHub Bot logged work on BEAM-6018: ---------------------------------------- Author: ASF GitHub Bot Created on: 09/Nov/18 16:51 Start Date: 09/Nov/18 16:51 Worklog Time Spent: 10m Work Description: lukecwik commented on a change in pull request #6994: [BEAM-6018] Fix slow memory leak in GcsUtil URL: https://github.com/apache/beam/pull/6994#discussion_r232320774 ########## File path: sdks/java/extensions/google-cloud-platform-core/src/main/java/org/apache/beam/sdk/util/GcsUtil.java ########## @@ -208,6 +211,8 @@ private GcsUtil( this.httpRequestInitializer = httpRequestInitializer; this.uploadBufferSizeBytes = uploadBufferSizeBytes; this.executorService = executorService; + this.batchExecutorService = Review comment: Instead of storing this here, why not just drop the "exiting" part of the executor service below? This way the thread pool has a limited lifecycle (when its being used) otherwise it gets dropped and the behavior will be very similar to before. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org Issue Time Tracking ------------------- Worklog Id: (was: 164412) Time Spent: 40m (was: 0.5h) > Memory leak in GCSUtil.java executeBatches > ------------------------------------------ > > Key: BEAM-6018 > URL: https://issues.apache.org/jira/browse/BEAM-6018 > Project: Beam > Issue Type: Bug > Components: io-java-gcp > Affects Versions: 2.7.0 > Reporter: Udi Meiri > Assignee: Udi Meiri > Priority: Major > Time Spent: 40m > Remaining Estimate: 0h > > In streaming pipelines there are multiple calls to moveToOutputFiles > (https://github.com/apache/beam/blob/42984a821b3e73aee2966d11d7fb436b5ff22b68/sdks/java/core/src/main/java/org/apache/beam/sdk/io/WriteFiles.java#L796). > When writing to GCS, this call uses executeBatches > (https://github.com/apache/beam/blob/279a05604b83a54e8e5a79e13d8761f94841f326/sdks/java/extensions/google-cloud-platform-core/src/main/java/org/apache/beam/sdk/util/GcsUtil.java#L551), > which wraps a thread pool in MoreExecutors.getExitingExecutorService(). This > wrapper introduces a DelayedShutdownHook which persists until the worker > exits. -- This message was sent by Atlassian JIRA (v7.6.3#76005)