Commit Graph

36 Commits

Author SHA1 Message Date
Birunthan Mohanathas
53132b56e3 Bug 1059390 - Part 5: Add and use CrashManager.generateSubmissionID(). r=gps 2014-09-02 10:02:40 -07:00
Birunthan Mohanathas
f2221e65ab Bug 1024672 - Part 5: Allow classifications to be stored in crash metadata. r=gps 2014-09-02 09:55:16 -07:00
Birunthan Mohanathas
890e39639a Bug 1059940 - Part 1: Expose CrashStore.reset() to clear all data. r=bsmedberg 2014-08-29 13:39:01 -07:00
Birunthan Mohanathas
cf3f9993c4 Bug 1059859 - Fix race condition in CrashManager._getStore() resulting in multiple stores being created. r=gps 2014-08-29 13:38:57 -07:00
Birunthan Mohanathas
394236da94 Bug 1059390 - Part 4: Fix crash submission event file handling and add test. r=bsmedberg
This also changes things to use a "sub-" prefix for the generated submission ID
in order to distinguish it from a local/remote crash ID.
2014-08-29 13:38:53 -07:00
Birunthan Mohanathas
82ac4cc4d6 Bug 1059390 - Part 3: Limit count only for new crash records in CrashStore._ensureCrashRecord. r=bsmedberg 2014-08-29 13:38:49 -07:00
Birunthan Mohanathas
b1313ffcd4 Bug 1059390 - Part 1: Allow remote Breakpad ID to be stored in crash metadata. r=gps 2014-08-28 21:03:02 -07:00
Birunthan Mohanathas
b809847eaf Bug 1024672 - Part 3: Remove CrashManager.addSubmission in favor of CrashManager.addSubmission{Attempt,Result}. r=gps 2014-08-21 15:43:50 -07:00
Birunthan Mohanathas
1c081f8552 Bug 1024672 - Part 2: Convert submission details stored in separate crash records to crash metadata. r=gps 2014-08-21 15:43:46 -07:00
Birunthan Mohanathas
6d02b6ce50 Bug 1024672 - Part 1: Allow submission details to be stored in crash metadata. r=gps 2014-08-21 15:43:42 -07:00
Bill McCloskey
98bdfe240c Bug 1046964 - Fix some JS warnings (r=ttaubert) 2014-08-19 17:27:58 -07:00
Drew Willcoxon
2258afd165 Bug 1009765 - Add GMP plugin crashes to FHR crash reporting (part 2: FHR, toolkit/components/crashes). r=gps 2014-08-08 15:41:07 -07:00
Birunthan Mohanathas
0d9eebac32 Bug 1049257 - Fix typo in CrashManager.addCrash() in order to update the crash date of existing items. r=gps 2014-08-07 21:52:05 -07:00
Gregory Szorc
1dd7d1f247 Bug 1045421 - Remove date time bomb from test_crash_manager.js, add logging; r=gfritzsche
There was a hard-coded date in test_crash_manager.js of around August 3,
2013. This meant that about a year later we would start to run into
boundary issues since we weren't wrapping Date.now() inside
CrashManager.jsm.

It turns out the actual value of DUMMY_DATE doesn't really matter. So,
the test has been changed to produce a value that is reasonably modern.

While I was debugging this, I noticed we're not getting logging in the
tests. So I added that.

--HG--
extra : rebase_source : 4e5534f5df70b01268790396481bdd3236dd8e8e
extra : amend_source : d73ea0a333fa9b0b9c65d890d6f34cb923861acd
2014-07-29 09:47:59 -07:00
Wes Kocher
39e80492ac Bug 1045419 - Disable test_crash_manager.js for failures on a CLOSED TREE r=me 2014-07-28 20:14:19 -07:00
Gregory Szorc
54c4d3b9ae Bug 1033836 - Convert TESTING_JS_MODULES to moz.build; r=glandium
--HG--
extra : rebase_source : 1cd9e402c507260358af7a93c6fb2fc91c24994b
2014-07-02 16:43:41 -07:00
Steven MacLeod
84d99bb465 Bug 994707 - Introduce crash submission events and handle them. r=bsmedberg
This introduces a new crash event type for submissions and handles
them in the Crash Manager. These crash submissions will also be counted
in FHR.

--HG--
extra : rebase_source : c37fc86cecc86aea0afdd8cfa7b31295aad3d6f8
2014-07-03 14:04:28 -04:00
Wes Kocher
4c1c6bcbf5 Backed out 3 changesets (bug 994707) for Valgrind and XPCShell bustage on a CLOSED TREE
Backed out changeset 76555f34c210 (bug 994707)
Backed out changeset 3dd92fb7c846 (bug 994707)
Backed out changeset 802779efce2b (bug 994707)
2014-07-01 11:04:30 -07:00
Steven MacLeod
8db622b654 Bug 994707 - Introduce crash submission events and handle them. r=bsmedberg
This introduces a new crash event type for submissions and handles
them in the Crash Manager. These crash submissions will also be counted
in FHR.

--HG--
extra : rebase_source : 41fb43f9588885033e49dccfaf9351ef805c476b
2014-07-01 12:52:23 -04:00
Drew Willcoxon
97246d948a Bug 983313 - Write crash events for plugin crashes and hangs (part 1: main changes). r=bsmedberg 2014-05-12 11:58:18 -07:00
David Rajchenbach-Teller
a3a68698b9 Bug 961665 - Fix typo in CrashManager's use of OS.File. r=gps 2014-03-13 09:50:24 -04:00
Gregory Szorc
76bf714c29 Bug 875562 - Part 9: Change Health Report to pull from crashes manager; r=bsmedberg, r=rnewman
This patch changes Firefox Health Report to pull crash counts from the
newly-implemented crash manager. The crash manager is now the canonical
source of crash data, so all the code for reading crash dump files from
disk has been removed.

This regresses the collection capability of Firefox Health Report by
removing plugin crashes and hangs from the reported values. This
regression is intended to be temporary and a follow-up bug will be
created to add plugin process event recording to the crash events
system.

This regression has been justified because the old crash reporting
mechanism was severely flawed and wasn't sending accurate data (not all
crashes were being saved to dumps and some dumps would be deleted).

--HG--
extra : amend_source : d54bb3bf9f740508cb4eda286536ce16a4c3bee5
2014-01-30 16:48:52 -08:00
Wes Kocher
51fb4209af Backed out changeset 21793ea94b09 (bug 875562) for ASAN xpcshell failures 2014-03-13 15:22:40 -07:00
Gregory Szorc
808ce3d50e Bug 875562 - Part 9: Change Health Report to pull from crashes manager; r=bsmedberg, r=rnewman
This patch changes Firefox Health Report to pull crash counts from the
newly-implemented crash manager. The crash manager is now the canonical
source of crash data, so all the code for reading crash dump files from
disk has been removed.

This regresses the collection capability of Firefox Health Report by
removing plugin crashes and hangs from the reported values. This
regression is intended to be temporary and a follow-up bug will be
created to add plugin process event recording to the crash events
system.

This regression has been justified because the old crash reporting
mechanism was severely flawed and wasn't sending accurate data (not all
crashes were being saved to dumps and some dumps would be deleted).

--HG--
extra : rebase_source : 7442a712d06b4d875010e78d4dd4f5cc179c8dfc
2014-01-30 16:48:52 -08:00
Ryan VanderMeulen
a2a03608f4 Backed out changesets c6ca1aa3887a, d741e117a033, 1fd26e822e73, and 720962c9f993 (bug 961665) for build bustage and xpcshell failures. 2014-03-13 10:32:57 -04:00
David Rajchenbach-Teller
f0f0fc98d1 Bug 961665 - Fix typo in CrashManager's use of OS.File. r=gps 2014-03-13 09:50:24 -04:00
Gregory Szorc
f6a52bbb63 Bug 976241 - Create crash store directory; r=Yoric
--HG--
extra : rebase_source : f23aed8ade10dba5f75cc904deddacb0aad1ad4f
2014-03-04 16:21:11 -08:00
Gregory Szorc
b1a42140bf NO BUG - Fix bustage in toolkit/components/crashes/tests/xpcshell/test_crash_manager.js; r=me 2014-02-14 14:53:47 -08:00
Gregory Szorc
1290f96f1d Bug 972093 - Detect run_next_test() during add_task(); r=ted, rnewman
If an xpcshell test called run_next_test() from inside an add_task(),
bad things would happen. This patch detects that behavior and aborts the
test immediately with an actionable error message.

--HG--
extra : rebase_source : c5cf11070421b95a6fcf476d0a86289a3d0ba73a
extra : amend_source : cec6ad2a751bba01e7d4ecbff0735b39e3326efb
2014-02-12 16:47:29 -08:00
Gregory Szorc
fc19689627 Bug 875562 - Part 7: Implement limits for stored crash data; r=Yoric
This patch institutes limits for how much crash data can be stored in
terms of maximum number of crash events per day. If more events than the
limit are encountered, we record that a high water mark has been
encountered and we silently discard the payload of future events.

We chose to not increment the version of the store payload because no
clients are actively saving this data yet, so it doesn't make sense to
incur a version bump.

--HG--
extra : rebase_source : 3d5d92668b38e8b9c3c45e1a61a3a172b576e0a5
extra : amend_source : 71fffa0724450c5fe13563d2539813e9a831b3de
2014-01-28 17:33:38 -08:00
Gregory Szorc
94c17fd393 Bug 875562 - Part 6: Implement initial crash events; r=bsmedberg
Support for main process crashes, plugin crashes, and plugin hangs is
added to the crash manager. This includes a JS API for reporting them as
well as support for reading the event files.

There is still an issue of unbound growth on the store. This will be
addressed in a subsequent patch.

--HG--
extra : rebase_source : e714bf5f9c2fd9c50f2e40659c3b1a89591f3b1a
2014-01-28 15:46:03 -08:00
Gregory Szorc
3eb241446a Bug 875562 - Part 5: Document crash events for initial implementation; r=bsmedberg
The initial implementation of this feature will write 3 distinct event
types and will only count occurrences of each. Future iterations of the
feature will capture more metadata, such as submission state and extra
crash annotations. These will not be included in this patch set.

DONTBUILD (NPOTB)

--HG--
extra : rebase_source : a1be4ceb6e06f2153d0927e50090c5f352b741d6
2014-01-28 12:00:10 -08:00
Gregory Szorc
9481222b1c Bug 875562 - Part 4: Add Support for crash event files to CrashManager; r=Yoric
This patch introduces the concepts of the "crash data store" and "crash
event files." The "crash data store" is a data store containing
information about crashes. Data is added to this store directly through
a JavaScript API or by the presence of "crash event files." A "crash
event file" is simply an individual file containing information about
a crash event. These files are periodically scanned and their contents
are merged into the store.

Currently, no specific event files types are defined. This patch merely
begins to implement the infrastructure for dealing with them. Support
for specific crash events will be added in subsequent patches.

--HG--
extra : rebase_source : c58017b514f31c2823bc8ef4158a42bba758a9ab
2014-01-27 15:49:11 -08:00
Gregory Szorc
f7fdf274a0 Bug 875562 - Part 3b: Review fixups; r=me
--HG--
extra : rebase_source : 1bbadefa0a86dd3c56c038089242647027c88d8f
2014-01-29 09:46:39 -08:00
Gregory Szorc
2c12c3f4d1 Bug 875562 - Part 3: XPCOM service for managing crash data; r=ted, bsmedberg
--HG--
extra : rebase_source : 4d4ce909634a079f1032c431bd639fef5b3f38ce
2014-01-23 15:49:24 -08:00
Gregory Szorc
72d5471898 Bug 875562 - Part 2: Create CrashManager API for managing crash data; r=ted, Yoric
The tree doesn't have a robust and reusable API for interfacing with
crash data. This patch is the start of a new API.

In this patch, the CrashManager type is introduced. It has APIs for
retrieving the lists of files related to crash dumps. In subsequent
patches, I will convert existing code in the tree that does similar
things to the new API. I will also build the events/timeline API onto
this type.

I made CrashManager generic because I hate, hate, hate singletons and
global variables. Allowing it to be instantiated multiple times with
different options (instead of say binding a global instance to ProfD)
makes the testing story much, much nicer. That is reason enough, IMO. In
a subsequent patch, I'll add an XPCOM service that instantiates the
"global" instance of CrashManager with the appropriate options.

It was tempting to add this code into the existing CrashReports.jsm.
However, this file does not import cleanly in xpcshell tests and I
didn't want to bloat scope to include fixing that file... yet.
CrashReports.jsm is using synchronous I/O. So, depending on how
adventerous I feel, I may replace consumers of CrashReports.jsm with the
new CrashManager.jsm, remove CrashReports.jsm, and eliminate another
source of synchronous I/O in the tree.

--HG--
extra : rebase_source : 379fa6a78b53bc0dea0c7c64e8b1bdcf85b61a7c
2013-11-19 14:08:25 -08:00