slfan1989 commented on code in PR #1281:
URL: https://github.com/apache/ratis/pull/1281#discussion_r2361539607


##########
ratis-server/src/test/java/org/apache/ratis/WatchRequestTests.java:
##########
@@ -302,7 +302,6 @@ static void checkAll(List<CompletableFuture<WatchReplies>> 
watches, Logger log)
       final WatchReplies watchReplies = watches.get(i).get(GET_TIMEOUT_SECOND, 
TimeUnit.SECONDS);
       final long logIndex = watchReplies.logIndex;
       log.info("checkAll {}: logIndex={}", i, logIndex);
-      final RaftClientReply watchAllReply = watchReplies.getAll();

Review Comment:
   This is a good question. When I encountered this error, I reviewed the code 
and found that the variable final RaftClientReply watchAllReply = 
watchReplies.getAll(); was not referenced anywhere else. Therefore, I removed 
this line of code, which allowed the unit tests to run successfully. As for the 
cause of the null pointer exception, I will investigate further and provide 
feedback.



##########
ratis-server/src/test/java/org/apache/ratis/WatchRequestTests.java:
##########
@@ -302,7 +302,6 @@ static void checkAll(List<CompletableFuture<WatchReplies>> 
watches, Logger log)
       final WatchReplies watchReplies = watches.get(i).get(GET_TIMEOUT_SECOND, 
TimeUnit.SECONDS);
       final long logIndex = watchReplies.logIndex;
       log.info("checkAll {}: logIndex={}", i, logIndex);
-      final RaftClientReply watchAllReply = watchReplies.getAll();

Review Comment:
   This is a good question. When I encountered this error, I reviewed the code 
and found that the variable final `RaftClientReply watchAllReply = 
watchReplies.getAll();` was not referenced anywhere else. Therefore, I removed 
this line of code, which allowed the unit tests to run successfully. As for the 
cause of the null pointer exception, I will investigate further and provide 
feedback.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to