Hacker News new | ask | show | jobs
by lifthrasiir 2042 days ago
> Many apps can get away with only using TAI, so they don't necessarily have to track the difference between UTC and TAI

Most systems don't need to keep the difference between UTC and TAI to display the UTC time anyway. TAI matters when you have to manipulate the non-zoned wall clock (as opposed to date and time components) and that's surprisingly rare.

> If your system uses TAI in its distributed coordination mechanisms, you don't need to worry about leap seconds and an error in the UTC-TAI difference won't cause your system to fail

This is a legitimate concern, but TAI is not the solution (you should probably be using PTP or GPS clock if you do care that much) nor an essential part of the solution (any monotonic clock, including "leap smears" and UTC-SLS, will do fine). In fact I think most perceived benefits of TAI are actually of monotonic clocks and not inherent to TAI, and UTC is already monotonic... (Yes, I'm distinguishing the actual UTC and time_t; for the latter there is a relatively simple conversion to monotonic however.)

1 comments

Yeah, you're right that the primary benefit of TAI is that it's monotonic - but it's better to have a globally consistent monotonic schelling point than to deal with every machine having its own detached monotonic clock.

> GPS clock

GPS and TAI are essentially the same, modulo a fixed 19 second offset.