You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@storm.apache.org by darionyaphet <gi...@git.apache.org> on 2016/06/14 13:31:35 UTC

[GitHub] storm pull request #1485: [STORM-1899] Release HBase connection when topolog...

GitHub user darionyaphet opened a pull request:

    https://github.com/apache/storm/pull/1485

    [STORM-1899] Release HBase connection when topology shutdown

    [STORM-1899](https://issues.apache.org/jira/browse/STORM-1899)
    
    Release HBase connection when topology shutdown

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/darionyaphet/storm STORM-1899

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/storm/pull/1485.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1485
    
----
commit 5788d83350bb82e53547cfb5830fd55669a40ee0
Author: darionyaphet <da...@gmail.com>
Date:   2016-06-14T13:28:12Z

    STORM-1899 : release HBase connection when topology shutdown

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] storm pull request #1485: [STORM-1899] Release HBase connection when topolog...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/storm/pull/1485


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] storm pull request #1485: [STORM-1899] Release HBase connection when topolog...

Posted by darionyaphet <gi...@git.apache.org>.
Github user darionyaphet commented on a diff in the pull request:

    https://github.com/apache/storm/pull/1485#discussion_r67004722
  
    --- Diff: external/storm-hbase/src/main/java/org/apache/storm/hbase/bolt/AbstractHBaseBolt.java ---
    @@ -73,4 +74,13 @@ public void prepare(Map map, TopologyContext topologyContext, OutputCollector co
             hbaseConfMap.put(Config.TOPOLOGY_AUTO_CREDENTIALS, map.get(Config.TOPOLOGY_AUTO_CREDENTIALS));
             this.hBaseClient = new HBaseClient(hbaseConfMap, hbConfig, tableName);
         }
    +
    +    @Override
    +    public void cleanup() {
    +        try {
    +            hBaseClient.close();
    +        } catch (IOException e) {
    +            LOG.error("HBase Client Close Failed");
    --- End diff --
    
    update and rebased \U0001f44d 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] storm issue #1485: [STORM-1899] Release HBase connection when topology shutd...

Posted by abhishekagarwal87 <gi...@git.apache.org>.
Github user abhishekagarwal87 commented on the issue:

    https://github.com/apache/storm/pull/1485
  
    +1


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] storm pull request #1485: [STORM-1899] Release HBase connection when topolog...

Posted by abhishekagarwal87 <gi...@git.apache.org>.
Github user abhishekagarwal87 commented on a diff in the pull request:

    https://github.com/apache/storm/pull/1485#discussion_r66972323
  
    --- Diff: external/storm-hbase/src/main/java/org/apache/storm/hbase/bolt/AbstractHBaseBolt.java ---
    @@ -73,4 +74,13 @@ public void prepare(Map map, TopologyContext topologyContext, OutputCollector co
             hbaseConfMap.put(Config.TOPOLOGY_AUTO_CREDENTIALS, map.get(Config.TOPOLOGY_AUTO_CREDENTIALS));
             this.hBaseClient = new HBaseClient(hbaseConfMap, hbConfig, tableName);
         }
    +
    +    @Override
    +    public void cleanup() {
    +        try {
    +            hBaseClient.close();
    +        } catch (IOException e) {
    +            LOG.error("HBase Client Close Failed");
    --- End diff --
    
    add the exception as well in log statement. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] storm issue #1485: [STORM-1899] Release HBase connection when topology shutd...

Posted by HeartSaVioR <gi...@git.apache.org>.
Github user HeartSaVioR commented on the issue:

    https://github.com/apache/storm/pull/1485
  
    While Storm doesn't guarantee that cleanup() will be called during shutdown, it will be better than now.
    +1


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] storm pull request #1485: [STORM-1899] Release HBase connection when topolog...

Posted by abhishekagarwal87 <gi...@git.apache.org>.
Github user abhishekagarwal87 commented on a diff in the pull request:

    https://github.com/apache/storm/pull/1485#discussion_r66972401
  
    --- Diff: external/storm-hbase/src/main/java/org/apache/storm/hbase/common/HBaseClient.java ---
    @@ -26,12 +26,13 @@
     import org.slf4j.Logger;
     import org.slf4j.LoggerFactory;
     
    +import java.io.Closeable;
     import java.io.IOException;
     import java.security.PrivilegedExceptionAction;
     import java.util.List;
     import java.util.Map;
     
    -public class HBaseClient {
    +public class HBaseClient implements Closeable{
    --- End diff --
    
    minor. space after Closeable. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---