You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zeppelin.apache.org by GitBox <gi...@apache.org> on 2021/08/25 07:13:30 UTC

[GitHub] [zeppelin] zjffdu opened a new pull request #4208: [ZEPPELIN-5497] Memory leak of GenericObjectPool

zjffdu opened a new pull request #4208:
URL: https://github.com/apache/zeppelin/pull/4208


   ### What is this PR for?
   
   Should close `clientPool` explicitly, otherwise it won't be garbage collected. 
   
   ### What type of PR is it?
   [Bug Fix]
   
   ### Todos
   * [ ] - Task
   
   ### What is the Jira issue?
   * https://issues.apache.org/jira/browse/ZEPPELIN-5497?filter=-2
   
   ### How should this be tested?
   * CI pass
   
   ### Screenshots (if appropriate)
   
   ### Questions:
   * Does the licenses files need update? No
   * Is there breaking changes for older versions? No
   * Does this needs documentation? No
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@zeppelin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zeppelin] zjffdu commented on pull request #4208: [ZEPPELIN-5497] Memory leak of GenericObjectPool

Posted by GitBox <gi...@apache.org>.
zjffdu commented on pull request #4208:
URL: https://github.com/apache/zeppelin/pull/4208#issuecomment-906021293


   @Reamer  I am afraid we can not use `try-with-resource` here, because `PooledRemoteClient` will be used in the whole lifecycle of `RemoteInterpreterProcess` (used in multiple places). 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@zeppelin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zeppelin] Reamer commented on pull request #4208: [ZEPPELIN-5497] Memory leak of GenericObjectPool

Posted by GitBox <gi...@apache.org>.
Reamer commented on pull request #4208:
URL: https://github.com/apache/zeppelin/pull/4208#issuecomment-906264572


   Some time ago I wrote similar code.
   https://github.com/apache/zeppelin/compare/master...Reamer:closeable_remote_client?expand=1
   Should I take over? I have included your correction in my change.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@zeppelin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zeppelin] Reamer commented on pull request #4208: [ZEPPELIN-5497] Memory leak of GenericObjectPool

Posted by GitBox <gi...@apache.org>.
Reamer commented on pull request #4208:
URL: https://github.com/apache/zeppelin/pull/4208#issuecomment-906172740


   Okay, I understand, but I think that the AutoCloseable interface is helpful for static code analyzers that can be part of the IDE.
   The interface can also be used independently of try-with-ressources.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@zeppelin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zeppelin] zjffdu closed pull request #4208: [ZEPPELIN-5497] Memory leak of GenericObjectPool

Posted by GitBox <gi...@apache.org>.
zjffdu closed pull request #4208:
URL: https://github.com/apache/zeppelin/pull/4208


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@zeppelin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zeppelin] Reamer commented on pull request #4208: [ZEPPELIN-5497] Memory leak of GenericObjectPool

Posted by GitBox <gi...@apache.org>.
Reamer commented on pull request #4208:
URL: https://github.com/apache/zeppelin/pull/4208#issuecomment-905393394


   We should implement the [`AutoCloseable` interface](https://docs.oracle.com/javase/8/docs/api/java/lang/AutoCloseable.html) in this class.
   Maybe we can use the `try-with-resources` statement in the class that uses the class.
   Of course we have to rename the function name from `shutdown` to `close`.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@zeppelin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zeppelin] zjffdu commented on pull request #4208: [ZEPPELIN-5497] Memory leak of GenericObjectPool

Posted by GitBox <gi...@apache.org>.
zjffdu commented on pull request #4208:
URL: https://github.com/apache/zeppelin/pull/4208#issuecomment-906269223


   Sure, @Reamer  please take over it 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@zeppelin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org