- Added buttons, JS to trigger logs to be generated.
- Added out params to return log paths.
- Added attributes to cycle collector interface to export log paths.
--HG--
extra : rebase_source : cbce2c62b577c820fd099706d72ab7b20992a00a
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
Many properties in OS.Constants.Path are dependent on the profile being
available. This patch improves their handling.
Previously, we had some repeated and boilerplate code for making
OS.Constants.Paths.<prop> a lazy getter. This patch eliminates the
boilerplate by iterating over the properties that need to be lazy
getters.
AppData and UAppData are now lazy getters.
test_profiledir.js has been rolled into test_path_constants.js.
test_path_constants.js now emits a warning when a comparison doesn't
test anything. This should help identify ineffective tests going
forward.
--HG--
extra : rebase_source : d142c5fc78eb894f78f9ac8745de3413e4919f09