Significant changes to Gecko L10n (Fluent migration to Rust)

21 views
Skip to first unread message

Zibi Braniecki

unread,
Jul 29, 2021, 1:06:58 PM7/29/21
to dev-pl...@mozilla.org, firefox-dev
Hi all,

I'm about to start landing a large refactor of the innermost part of our localization system - Fluent.

The purpose of the refactor is to improve performance and reliability of Fluent in Gecko and unblock a Fission task of sharing localization resources between processes.
This change is part of my team's 2021 Roadmap to streamline I18n component in Gecko.

Finally, Rust version of L10nRegistry has a fix pending to the catastrophic backtracking problem [0][1] edge case scenario that some of our users end up in.

The patchset is divided into three logical parts:


The refactor doesn't change the core API design, but it has two observable changes:

1) The timing of micro-tasks around async localization changes
2) Custom L10nRegistry instances and custom locale lists can be passed to Localization, DOMLocalization and DocumentL10n constructors instead of generator wrapper like we had before.

The latter is only important in complete edge cases that hopefully none of you ever has to work with, but the former may impact some tests that were not properly constructed to await async localization and instead relied on the micro task ordering.

I tried to fix as many of them as possible, but it is possible that some racy intermittent oranges will become perma-oranges. Hopefully this will make it easier to fix :)

My plan is to land the FileSource patchset today, L10nRegistry tomorrow and then focus on Localization next week.

If you notice anything unusual, plese, reach out to me on Matrix or Slack or in the bug.

Thank you!
zb.

--
You received this message because you are subscribed to the Google Groups "firef...@mozilla.org" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firefox-dev...@mozilla.org.
To view this discussion on the web visit https://groups.google.com/a/mozilla.org/d/msgid/firefox-dev/CANj%3Dv2_tDSscBO5xqyUZ2GMpnbKFuZfcLBZtyHR4skh_K%3D4nCQ%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages