[
https://issues.apache.org/jira/browse/TAJO-1391?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14358692#comment-14358692
]
ASF GitHub Bot commented on TAJO-1391:
--------------------------------------
Github user ykrips commented on a diff in the pull request:
https://github.com/apache/tajo/pull/412#discussion_r26302284
--- Diff: tajo-rpc/src/main/java/org/apache/tajo/rpc/AsyncRpcClient.java ---
@@ -113,16 +87,11 @@ public void close() {
}
private class ProxyRpcChannel implements RpcChannel {
- private final ClientChannelInboundHandler handler;
-
- public ProxyRpcChannel() {
- this.handler = getChannel().pipeline()
- .get(ClientChannelInboundHandler.class);
+ private ClientChannelInboundHandler handler;
- if (handler == null) {
- throw new IllegalArgumentException("Channel does not have " +
- "proper handler");
- }
+ private ClientChannelInboundHandler handler() {
+ return handler == null ? handler = getChannel().pipeline()
--- End diff --
getChannel() function has a possibility to return null when channelfuture
is null, so it needs check null value.
> RpcConnectionPool should check reference counter of connection before close
> ---------------------------------------------------------------------------
>
> Key: TAJO-1391
> URL: https://issues.apache.org/jira/browse/TAJO-1391
> Project: Tajo
> Issue Type: Improvement
> Components: rpc
> Reporter: Navis
> Assignee: Navis
>
> Connections in the pool is shared one and should be closed only when it's not
> referenced by other threads. Furthermore, current pool implementation locks
> whole connections for connecting/closing a connection, making bad
> interferences on other operations (on sane connection).
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)