You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ratis.apache.org by "Hadoop QA (JIRA)" <ji...@apache.org> on 2018/01/18 03:32:00 UTC

[jira] [Commented] (RATIS-193) RaftClientProtocolService can close a stream twice on error

    [ https://issues.apache.org/jira/browse/RATIS-193?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16329945#comment-16329945 ] 

Hadoop QA commented on RATIS-193:
---------------------------------

| (x) *{color:red}-1 overall{color}* |
\\
\\
|| Vote || Subsystem || Runtime || Comment ||
| {color:blue}0{color} | {color:blue} reexec {color} | {color:blue}  0m  7s{color} | {color:blue} Docker mode activated. {color} |
|| || || || {color:brown} Prechecks {color} ||
| {color:blue}0{color} | {color:blue} findbugs {color} | {color:blue}  0m  0s{color} | {color:blue} Findbugs executables are not available. {color} |
| {color:green}+1{color} | {color:green} @author {color} | {color:green}  0m  0s{color} | {color:green} The patch does not contain any @author tags. {color} |
| {color:red}-1{color} | {color:red} test4tests {color} | {color:red}  0m  0s{color} | {color:red} The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. {color} |
|| || || || {color:brown} master Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  0m 56s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 47s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} checkstyle {color} | {color:green}  0m 14s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 29s{color} | {color:green} master passed {color} |
|| || || || {color:brown} Patch Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  0m 56s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 45s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javac {color} | {color:green}  0m 45s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} checkstyle {color} | {color:green}  0m 14s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} whitespace {color} | {color:green}  0m  0s{color} | {color:green} The patch has no whitespace issues. {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 30s{color} | {color:green} the patch passed {color} |
|| || || || {color:brown} Other Tests {color} ||
| {color:red}-1{color} | {color:red} unit {color} | {color:red}  5m 59s{color} | {color:red} root in the patch failed. {color} |
| {color:green}+1{color} | {color:green} asflicense {color} | {color:green}  0m  6s{color} | {color:green} The patch does not generate ASF License warnings. {color} |
| {color:black}{color} | {color:black} {color} | {color:black} 11m 11s{color} | {color:black} {color} |
\\
\\
|| Reason || Tests ||
| Failed junit tests | ratis.server.simulation.TestRaftWithSimulatedRpc |
|   | ratis.server.simulation.TestReinitializationWithSimulatedRpc |
\\
\\
|| Subsystem || Report/Notes ||
| Docker | Client=17.05.0-ce Server=17.05.0-ce Image:yetus/ratis:date2018-01-18 |
| JIRA Issue | RATIS-193 |
| JIRA Patch URL | https://issues.apache.org/jira/secure/attachment/12906184/RATIS-193.001.patch |
| Optional Tests |  asflicense  javac  javadoc  unit  findbugs  checkstyle  compile  |
| uname | Linux dbf5bca4a1b0 3.13.0-135-generic #184-Ubuntu SMP Wed Oct 18 11:55:51 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux |
| Build tool | maven |
| Personality | /home/jenkins/jenkins-slave/workspace/PreCommit-RATIS-Build/yetus-personality.sh |
| git revision | master / 8cac9d5 |
| Default Java | 1.8.0_151 |
| unit | https://builds.apache.org/job/PreCommit-RATIS-Build/97/artifact/out/patch-unit-root.txt |
|  Test Results | https://builds.apache.org/job/PreCommit-RATIS-Build/97/testReport/ |
| modules | C: ratis-grpc U: ratis-grpc |
| Console output | https://builds.apache.org/job/PreCommit-RATIS-Build/97/console |
| Powered by | Apache Yetus 0.5.0   http://yetus.apache.org |


This message was automatically generated.



> RaftClientProtocolService can close a stream twice on error
> -----------------------------------------------------------
>
>                 Key: RATIS-193
>                 URL: https://issues.apache.org/jira/browse/RATIS-193
>             Project: Ratis
>          Issue Type: Bug
>            Reporter: Mukul Kumar Singh
>            Assignee: Mukul Kumar Singh
>            Priority: Major
>         Attachments: RATIS-193.001.patch
>
>
> In case of errors in RaftClientProtocolService.java, on error {{responseObserver.onError(RaftGrpcUtil.wrapException(t));}} will be called which will close the stream observer. This can lead into a case where stream in closed twice in cases of errors. A check similar to RATIS-189 should be added as well.
>  
> {code:java}
> 2018-01-16 11:57:09,810 [grpc-default-executor-3] WARN  client.RaftClientProtocolService (RaftClientProtocolService.java:responseError(186)) - 127.0.0.1_54322-16: Failed processClientRequestAsync for RaftClientRequest(client-8764D94435EE->127.0.0.1_54322) in group-7347726F7570, cid=4, seq=0 RW, 08011224613033313231...(size=291)
> org.apache.ratis.protocol.LeaderNotReadyException: 127.0.0.1_54322 is in LEADER state but not ready yet.
>         at org.apache.ratis.server.impl.RaftServerImpl.checkLeaderState(RaftServerImpl.java:377)
>         at org.apache.ratis.server.impl.RaftServerImpl.submitClientRequestAsync(RaftServerImpl.java:454)
>         at org.apache.ratis.server.impl.RaftServerProxy.submitClientRequestAsync(RaftServerProxy.java:147)
>         at org.apache.ratis.grpc.client.RaftClientProtocolService$AppendRequestStreamObserver.processClientRequestAsync(RaftClientProtocolService.java:125)
>         at org.apache.ratis.util.SlidingWindow$Server.processRequestsFromHead(SlidingWindow.java:351)
>         at org.apache.ratis.util.SlidingWindow$Server.receivedRequest(SlidingWindow.java:343)
>         at org.apache.ratis.grpc.client.RaftClientProtocolService$AppendRequestStreamObserver.onNext(RaftClientProtocolService.java:145)
>         at org.apache.ratis.grpc.client.RaftClientProtocolService$AppendRequestStreamObserver.onNext(RaftClientProtocolService.java:109)
>         at org.apache.ratis.shaded.io.grpc.stub.ServerCalls$2$1.onMessage(ServerCalls.java:206)
>         at org.apache.ratis.shaded.io.grpc.internal.ServerCallImpl$ServerStreamListenerImpl.messageRead(ServerCallImpl.java:237)
>         at org.apache.ratis.shaded.io.grpc.internal.ServerImpl$JumpToApplicationThreadServerStreamListener$1.runInContext(ServerImpl.java:485)
>         at org.apache.ratis.shaded.io.grpc.internal.ContextRunnable.run(ContextRunnable.java:52)
>         at org.apache.ratis.shaded.io.grpc.internal.SerializingExecutor$TaskRunner.run(SerializingExecutor.java:154)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>         at java.lang.Thread.run(Thread.java:745)
> Jan 16, 2018 11:57:09 AM org.apache.ratis.shaded.io.grpc.internal.SerializingExecutor$TaskRunner run
> {code}
> stream is closed again here
> {code}
> SEVERE: Exception while executing runnable org.apache.ratis.shaded.io.grpc.internal.ServerImpl$JumpToApplicationThreadServerStreamListener$2@7edacaf
> java.lang.IllegalStateException: call already closed
>         at org.apache.ratis.shaded.com.google.common.base.Preconditions.checkState(Preconditions.java:174)
>         at org.apache.ratis.shaded.io.grpc.internal.ServerCallImpl.close(ServerCallImpl.java:178)
>         at org.apache.ratis.shaded.io.grpc.stub.ServerCalls$ServerCallStreamObserverImpl.onCompleted(ServerCalls.java:304)
>         at org.apache.ratis.grpc.client.RaftClientProtocolService$AppendRequestStreamObserver.close(RaftClientProtocolService.java:179)
>         at org.apache.ratis.grpc.client.RaftClientProtocolService$AppendRequestStreamObserver.onCompleted(RaftClientProtocolService.java:172)
>         at org.apache.ratis.shaded.io.grpc.stub.ServerCalls$2$1.onHalfClose(ServerCalls.java:217)
>         at org.apache.ratis.shaded.io.grpc.internal.ServerCallImpl$ServerStreamListenerImpl.halfClosed(ServerCallImpl.java:260)
>         at org.apache.ratis.shaded.io.grpc.internal.ServerImpl$JumpToApplicationThreadServerStreamListener$2.runInContext(ServerImpl.java:503)
>         at org.apache.ratis.shaded.io.grpc.internal.ContextRunnable.run(ContextRunnable.java:52)
>         at org.apache.ratis.shaded.io.grpc.internal.SerializingExecutor$TaskRunner.run(SerializingExecutor.java:154)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>         at java.lang.Thread.run(Thread.java:745)
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)