You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ratis.apache.org by sh...@apache.org on 2020/04/29 15:04:10 UTC

[incubator-ratis] branch master updated: RATIS-912. Failed UT: RejectedExecutionException: event executor terminated. (#75)

This is an automated email from the ASF dual-hosted git repository.

shashikant pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-ratis.git


The following commit(s) were added to refs/heads/master by this push:
     new 3b87d69  RATIS-912. Failed UT: RejectedExecutionException: event executor terminated. (#75)
3b87d69 is described below

commit 3b87d6978036bd285353f456a953a7a98ac2a00f
Author: Lokesh Jain <lj...@apache.org>
AuthorDate: Wed Apr 29 20:34:01 2020 +0530

    RATIS-912. Failed UT: RejectedExecutionException: event executor terminated. (#75)
---
 .../src/main/java/org/apache/ratis/netty/server/NettyRpcService.java  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ratis-netty/src/main/java/org/apache/ratis/netty/server/NettyRpcService.java b/ratis-netty/src/main/java/org/apache/ratis/netty/server/NettyRpcService.java
index 863be84..de5f6de 100644
--- a/ratis-netty/src/main/java/org/apache/ratis/netty/server/NettyRpcService.java
+++ b/ratis-netty/src/main/java/org/apache/ratis/netty/server/NettyRpcService.java
@@ -143,6 +143,8 @@ public final class NettyRpcService extends RaftServerRpcWithProxy<NettyRpcProxy,
 
   @Override
   public void closeImpl() throws IOException {
+    final ChannelFuture f = getChannel().close();
+    f.syncUninterruptibly();
     bossGroup.shutdownGracefully();
     workerGroup.shutdownGracefully();
     try {
@@ -151,9 +153,7 @@ public final class NettyRpcService extends RaftServerRpcWithProxy<NettyRpcProxy,
     } catch (InterruptedException e) {
       LOG.error("Interrupt EventLoopGroup terminate", e);
     }
-    final ChannelFuture f = getChannel().close();
     super.closeImpl();
-    f.syncUninterruptibly();
   }
 
   @Override