Open Bug 1950941 Opened 6 months ago Updated 2 months ago

Split the `nsIApplicationUpdateService` interface into two: one that requires the mutex and one that does not

Categories

(Toolkit :: Application Update, task, P2)

task

Tracking

()

People

(Reporter: bytesized, Unassigned)

References

(Depends on 1 open bug)

Details

The issue here is basically described by Bug 1900717 Comment 1, but I'll restate it.

The way that we handle the update mutex now is a bit of a problem. It's common for us to do something like:

  1. Start up Firefox
  2. Cannot acquire the mutex, but we still load active-update.xml and updates.xml.
  3. Time passes
  4. We acquire the mutex, but we do not reload active-update.xml and updates.xml.
  5. We operate on stale data.

This is a deceptively difficult problem to fix. We don't want to fix it in such a way that the state completely changes between synchronous calls into the application update service, as that could make consuming it safely nearly impossible. So I plan to reorganize this into two separate interfaces, one that can be accessed without the update mutex, one that can only be accessed with the mutex. I believe that this will make it much more reasonable for consumers to use the interface safely.

Assignee: bytesized → nobody
You need to log in before you can comment on or make changes to this bug.