Open Bug 1822482 Opened 2 years ago Updated 2 years ago

Investigate whether glean can switch from chrono to time 0.3

Categories

(Data Platform and Tools :: Glean: SDK, task, P4)

task

Tracking

(Not tracked)

People

(Reporter: glandium, Unassigned)

References

Details

Attachments

(1 file)

Firefox currently depends on both time 0.1 and time 0.3. The main blocker to remove the former is chrono, which is taking forever to update to time 0.1. OTOH, a number of projects that were using chrono have ended up just switching to plain time 0.3 instead because of that. So I was wondering if that was an option that would work for us too.

so fwiw time 0.3 has nearly all functionality we need, but this needs some focused work:

  • provide a wrapper to handle (de)serialization. chrono serializes datetimes as an ISO8601 string. We need to manually do that for time so that we stay backwards-compatible with the stored data
  • time::precise_time_ns() is gone, but I think we can now rely on libstd's Instant::now() for our use cases. This needs verification though.
  • Bunch of type changes, including in a number of tests. Busy-work, but someone needs to do it.

This is from a first quick look and not a full implementation. Maybe I can put up a WIP commit though.

See Also: → 1780401
Priority: -- → P3
Priority: P3 → P4
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: