Граф коммитов

34 Коммитов

Автор SHA1 Сообщение Дата
Shu-yu Guo 64db2267cf Bug 1202902 - Mass replace toplevel 'let' with 'var' in preparation for global lexical scope. (rs=jorendorff) 2015-09-15 11:19:45 -07:00
Alexandre Lissy 4bf7163f65 Bug 1187419 - Make sure SettingsRequestManager is only loaded in parent. r=gwagner 2015-07-24 12:32:00 +02:00
Alexandre Lissy 4bf34df9d8 Bug 1119727 - Make Settings Soft Lockup threshold configurable. r=gwagner
--HG--
extra : rebase_source : 302514082703e2e550c7074c30a4a63eb1ac12f2
2015-07-21 12:15:00 +02:00
Andrea Marchesini 3aa189b5ff Bug 1163388 - patch 2 - get rid of nsIDOMFile, r=ehsan
--HG--
rename : dom/base/nsIDOMFile.idl => dom/base/nsIDOMBlob.idl
2015-05-18 14:52:26 +01:00
Alexandre Lissy d20d93f371 Bug 1128489 - Direct communication between SettingsService and SettingsRequestManager. r=qdot 2015-02-03 02:45:00 +01:00
Alexandre Lissy 2d0507f80d Bug 1107329 - Add locks tasks queue vivacity checking. r=qdot
To help diagnosing further issues with the Settings API getting blocked,
we add some tracking of the tasks and locks queue vivacity. We ensure to
keep track of the last lock id at the head of the queue, and we verify
whether it does not stays on top of it for too long.
2014-12-24 01:30:00 -05:00
Alexandre Lissy 2307cf43b4 Bug 1109704 - Expose details settings informations in about:memory. r=qdot
We want to have a better breakdown of how many get/set operations we are
doing for each setting lock. Given that we keep track of all locks, this
may consume quite some memory, so we introduce a new preference to
enable this feature. We also add memory reporting for the SettingService
lock.
2014-12-17 10:40:00 -05:00
Alexandre Lissy 17c05a60ab Bug 1110063 - Open readonly transaction for settings lock when possible. r=qdot
Whenever a settings lock does only read operations (i.e. lock.get()),
there is no need that the underlying indexedDB transaction should be
opened as readwrite. Doing so, we will be able to parallelize some
request and avoid locking that should in the end allow for faster
operations. Enabling this feature is controlled by the preference
dom.mozSettings.allowForceReadOnly, defaulting to false for now.
2014-12-17 09:30:00 -05:00
Alexandre Lissy 51143af486 Bug 1110091 - Fix mozSettings logging use of Services. r=qdot 2014-12-11 03:32:00 +01:00
Kyle Machulis 0636c32ce5 Bug 1105511 - Make observer principal cache name reflect content; r=gerard-majax 2014-12-09 13:53:20 -08:00
Kyle Machulis acc7048fe4 Bug 1105511 - Store principals with locks instead of with tasks; r=gerard-majax 2014-12-09 13:53:04 -08:00
Kyle Machulis ac9724ff1e Bug 1105511 - Check validity of principals before doing permissions check; r=gerard-majax 2014-12-09 13:52:46 -08:00
L. David Baron 568297df70 Bug 1106324 - Call removeLock in case where the call was missing. r=qdot
While I was debugging bug 1105511, khuey noticed that one case was
missing a removeLock call.  We should add it; it seems like if we ever
hit this error case, the settings lock queue would get stuck.  It's not
clear whether this is actually the cause of bug 1105511, so I'm putting
it in a separate bug.
2014-11-29 14:47:46 -08:00
Alexandre Lissy 7b995f0ea3 Bug 1106896 - Improve debug and error reporting in mozSettings. r=qdot
We break down the logging capabilities into two classes: debug and
verbose. Verbose will help to track everything that happens, while debug
should just report error cases. We also augment memory reports with
values to help tracking potential issues like: queue blockage, leaking,
etc.
2014-12-02 14:50:00 +01:00
Edgar Chen 4e8ea293f3 Bug 1092941 - Settings lock in parent isn't finialized when receiving 'child-process-shutdown'. r=lissyx, a=me 2014-11-03 15:15:12 +08:00
Alexandre Lissy 7413aa0cdc Bug 1082001 - Cleanup settings lock from parent itself. r=bent
From bug 1065128 SettingsManager has been changed to listen the
dom-window-destroyed event for its cleanup. However, when running Gaia
in Mulet, a race condition is exposed. For B2G, when loading a page,
about:blank is first used. This means that window destroyed events will
be triggered. However, from the dom-window-destroyed event we cannot
distinguish whether this is about:blank or a legit application being
closed. SettingsManager gets initialized (i.e., init() called) when the
application makes use of navigator.mozSettings. So the chain of event is
that we have a SettingsManager living because System app did some
request. At this time, about:blank is being unloaded and triggers a
dom-window-destroyed event. This makes SettingsManager doing its
cleanup, especially freeing the window reference. Then in the meantime,
we have the navigator.mozSettings use that is progressing. At some
point, SettingsManager has no more window to send messages to, and Gaia
is not able to even start.

SettingsRequestManager lives on the parent process and SettingsManager
lives on the child side. Part of the cleanup performed by
SettingsManager was to ensure pending locks on the parent process would
be forced to finalize to make sure those are being properly committed.
We move this cleanup to SettingsRequestManager and we augment the lock
informations with the proper inner window id. This way we can track
which lock is attached to which inner window when the lock gets created.
And thus we can listen on inner-window-destroyed from
SettingsRequestManager to be able to force finalize on any pending lock.
Impacted code path are those were we are not running out of process.
When we are running out of process, SettingsRequestManager already
listens on the child-process-shutdown event to perform the lock
finalization.
2014-10-29 02:36:00 -04:00
Gregor Wagner 119c8d2cb4 Bug 1080847 - [Settings] No need to export SettingsRequestManager r=baku 2014-10-21 13:48:42 -07:00
Alexandre Lissy 2373f7c83f Bug 1076597 - Fix Settings API shutdown race condition. r=bent
When child message manager dies, it sends a child-process-shutdown
message to the SettingsRequestManager. This would just close the locks
and tasks of this message manager. The race happens when some
applications can shutdown quickly: settings requests will never be
committed to the database. One example is the callscreen. The fix,
provided by qDot, simply put those tasks in a finalize state to make
sure they are properly executed and committed.
2014-10-09 05:12:00 -04:00
Ryan VanderMeulen 67e6833bd6 Backed out changeset 69866036d793 (bug 1076597) for being the wrong patch that landed. 2014-10-21 10:12:56 -04:00
Alexandre Lissy 343378644a Bug 1076597 - Fix Settings API shutdown race condition. r=bent 2014-10-07 06:35:00 -04:00
Ting-Yu Chou 149aa09b67 Bug 1064800 - Catch exception from sending message to prevent interrupting execution. r=khuey 2014-10-02 10:57:48 +08:00
Mike Habicher c0376bc34a Bug 1053966 - move mozsettings-changed Observer info from aSubject to aData, r=bz,qDot 2014-09-16 13:15:16 -04:00
Kyle Machulis 4cb996a29c Bug 1069605 - Make sure settings lock exists before trying to remove it; r=bent 2014-09-18 17:23:27 -07:00
Kyle Machulis e752fcb527 Bug 1068962 - Fix task cleanup on settings locks where finalize has already been called; r=bent
--HG--
extra : rebase_source : 18992e6c2e0277d2866fe92048b52a0a55a55ee6
2014-09-18 13:43:40 -07:00
Ryan VanderMeulen d3fce43e7e Backed out changeset ed586ca080c0 (bug 1053966) for the same Mnw permafails it was backed out for previously. 2014-09-16 16:54:25 -04:00
Mike Habicher e9ff4e12a0 Bug 1053966 - move mozsettings-changed Observer info from aSubject to aData, r=bz,qDot 2014-09-16 13:15:16 -04:00
Kyle Machulis ce3b825689 Bug 1065128 - Fix SettingsRequestManager storage of MessageManager Principals; r=bent 2014-09-15 13:39:20 -07:00
Kyle Machulis b979b13529 Bug 1061805 - Make sure Settings API only calls finalize once; r=bent 2014-09-15 09:29:29 -07:00
Kyle Machulis ac100d8a06 Bug 1062087 - Fix undefined variable error messages in Settings API; r=bent 2014-09-05 18:39:54 -07:00
Kyle Machulis 086f4f8e2b Bug 1061510 - Make settings api always check principals for permissions; r=bent
--HG--
extra : rebase_source : ece6c6808f391f5dd0661cb3c7acbc942d8bb4ac
2014-09-04 11:15:10 -07:00
Kyle Machulis 54c4948e67 Bug 1060691 - Clean up settings api debug messages; r=gwagner a=2.1 2014-08-29 16:36:02 -07:00
Kyle Machulis 7d5df891b8 bug 900551 - Settings API OOP; r=bent 2014-08-27 21:01:29 -07:00
Ryan VanderMeulen a408d636f2 Backed out 11 changesets (bug 1059079, bug 1015518, bug 900551, bug 846200) for Gaia UI test failures on a CLOSED TREE.
Backed out changeset d85b4e48b3b4 (bug 1015518)
Backed out changeset 663b73ba69ec (bug 1015518)
Backed out changeset 5cf1cb5fa022 (bug 900551)
Backed out changeset b953dd5bfdaa (bug 900551)
Backed out changeset a2b6d7c84100 (bug 900551)
Backed out changeset ceb79fe83d15 (bug 900551)
Backed out changeset f6acf344fbf0 (bug 900551)
Backed out changeset fa269ea53937 (bug 846200)
Backed out changeset b89c84a850f9 (bug 846200)
Backed out changeset b7a7dfbe4e3f (bug 846200)
Backed out changeset c6f54d821c11 (bug 1059079)
2014-08-28 12:49:49 -04:00
Kyle Machulis 91d2336a9b Bug 900551 - Settings API OOP; r=bent 2014-08-27 21:01:29 -07:00