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.
---
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 [email protected] or file a JIRA ticket
with INFRA.
---