You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@gobblin.apache.org by GitBox <gi...@apache.org> on 2022/03/25 17:04:27 UTC

[GitHub] [gobblin] ZihanLi58 commented on a change in pull request #3486: [GOBBLIN-1616] Add close connection logic in salseforceSource

ZihanLi58 commented on a change in pull request #3486:
URL: https://github.com/apache/gobblin/pull/3486#discussion_r835458789



##########
File path: gobblin-core/src/main/java/org/apache/gobblin/source/extractor/extract/restapi/RestApiConnector.java
##########
@@ -192,8 +190,8 @@ private static boolean hasId(JsonObject json) {
         if (httpEntity != null) {
           EntityUtils.consume(httpEntity);
         }
-        if(httpResponse instanceof CloseableHttpResponse) {
-          this.closer.register((CloseableHttpResponse)httpResponse);
+        if(httpResponse instanceof Closeable) {
+          this.closer.register((Closeable)httpResponse);

Review comment:
       I just want to make sure those lines will be executed no matter what happens during the execution to avoid any resource leak. Will address the code format 




-- 
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@gobblin.apache.org

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