Stops the acceptor, optionally waiting for it to finish. @param waitMilliseconds The number of milliseconds to wait for the acceptor to stop
(int waitMilliseconds)
| 186 | * @param waitMilliseconds The number of milliseconds to wait for the acceptor to stop |
| 187 | */ |
| 188 | public void stopMillis(int waitMilliseconds) { |
| 189 | stopCalled = true; |
| 190 | if (waitMilliseconds > 0) { |
| 191 | try { |
| 192 | if (!stopLatch.await(waitMilliseconds, TimeUnit.MILLISECONDS)) { |
| 193 | log.warn(sm.getString("acceptor.stop.fail", getThreadName())); |
| 194 | } |
| 195 | } catch (InterruptedException e) { |
| 196 | log.warn(sm.getString("acceptor.stop.interrupted", getThreadName()), e); |
| 197 | } |
| 198 | } |
| 199 | } |
| 200 | |
| 201 | |
| 202 | /** |
no test coverage detected