szetszwo commented on PR #1168:
URL: https://github.com/apache/ratis/pull/1168#issuecomment-2421216694
- Version 1
```java
synchronized (server) {
future = state.shutdown();
while (!future.isDone()) {
server.wait();
}
}
```
```java
try {
run();
} finally {
stopped.complete();
synchronized (server) {
server.notify();
}
}
```
- Version 2
```java
synchronized (server) {
future = state.shutdown();
}
future.join()
```
```java
try {
run();
} finally {
stopped.complete();
}
```
Version 1 and Version 2 seem to be the same. Could you point out when they
will be different?
--
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]