Open Bug 1620998 (oop-crashreporter) Opened 5 years ago Updated 25 days ago

Write a crash monitor program to handle annotations and minidump writing

Categories

(Toolkit :: Crash Reporting, task)

task

Tracking

()

ASSIGNED

People

(Reporter: gsvelto, Assigned: gsvelto)

References

(Blocks 13 open bugs)

Details

Attachments

(1 file, 1 obsolete file)

We should write a stand-alone program that can be launched by Firefox that will receive and gather crash annotations for the various processes and write out minidumps when requested to.

The program will have to communicate with Firefox over simple IPC. It will be able to accept a limited list of commands which will include:

  • Establishing an IPC channel with newly created processes
  • Writing out the minidump of a crashed process
  • Writing out the minidump of a running process
  • Writing out the crash annotations (.extra file) of a given process
  • Launching the crash reporter client if the main process crashes
Blocks: 1621000
Blocks: 1678591

Tentatively tracking this bug for Fission because this crash monitor may be the solution for bug 1594529 (which is blocking WebGL remoting for Fission).

Blocks: 1594529
Fission Milestone: --- → M7

(In reply to Chris Peterson [:cpeterson] from comment #1)

Tentatively tracking this bug for Fission because this crash monitor may be the solution for bug 1594529 (which is blocking WebGL remoting for Fission).

Correction: Untracking for Fission. Gabriele says this crash monitor will be a big change and he recommends that we not block Fission waiting for it.

Fission Milestone: M7 → ---
Blocks: 1683552
Depends on: 1759682
No longer depends on: 1759682
Depends on: 1776197
Severity: normal → S3
See Also: → 1799225
Blocks: 1816229
Alias: oop-crashreporter
Blocks: 1837903
Blocks: 1838482
Depends on: 1892401
Depends on: 1892403
Depends on: 1892408

A few words about the WIP here. This covers the basic structure of the OOP crash reporter, which includes:

  • One executable (crashmonitor) which contains the logic required from generating full crash reports, this will be used on Linux, macOS and Windows (currently only Linux is supported and it's a bit hacky)
  • A shared library with JNI methods for use on Android which contains the same logic as the executable
  • An Android service implemented in Java which loads said shared library. I've chosen a service here instead of using a regular class (or even an executable-like library like Crashpad does) because it allows the service to be killed and restarted, and the restarts can happen on demand. This will be very handy in case we hit a crash while the service has been killed
  • A bunch of changes that move all the logic used to fetch crash annotations from the main process into the crashmonitor process (or Android service). This includes a bunch of changes which rip out the related Rust/C++ glue, greatly simplifying the resulting code

There's quite a few things missing:

  • A client crate to access the functionality of the crash monitor. I've got a WIP of this too but it's even cruder than the rest of the code. This will implement an IPC channel to request minidumps and retrieve the results. It will also run in parallel with Breakpad's own IPC mechanism, that will only be replaced once we deal with bug 1620990 at a later point
  • The logic to actually fetch the minidumps from the external process and insert them in the regular crash reporting flow
  • Windows & macOS implementations
Assignee: nobody → gsvelto
Status: NEW → ASSIGNED
Depends on: 1896636
Depends on: 1896650
Depends on: 1896845
Attachment #9397625 - Attachment is obsolete: true
Depends on: 1898180
Depends on: 1899524
Depends on: 1903583
Blocks: 587729
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: