2

My servers and desktops are configured to automatically adjust their time via network ntp time servers.

This means that if I use the easy method beginDate.getTime()-new Date().getTime(), there is a chance I'm not getting an accurate number of elapsed milliseconds.

How can I write code that is immune to system clock updates and leap second adjustments?

Ole V.V.
  • 76,217
  • 14
  • 120
  • 142
Andrew Parks
  • 499
  • 4
  • 15

0 Answers0