Switch `jdk.httpserver` from wall clock to a monotonic one. This effectively 
fixes elapsed time measurements and scheduled event fire instants. Bonus: 
improves the test stability.

In short, replaced the `System.currentTimeMillis()` & `java.util.Timer` 
combination with the `System.nanoTime()` & `ScheduledExecutorService` 
alternative.

---------
- [X] I confirm that I make this contribution in accordance with the [OpenJDK 
Interim AI Policy](https://openjdk.org/legal/ai).

-------------

Commit messages:
 - Replace the wall clock with a monotonic one

Changes: https://git.openjdk.org/jdk/pull/33890/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=33890&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8397254
  Stats: 75 lines in 1 file changed: 53 ins; 7 del; 15 mod
  Patch: https://git.openjdk.org/jdk/pull/33890.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/33890/head:pull/33890

PR: https://git.openjdk.org/jdk/pull/33890

Reply via email to