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

266 Коммитов

Автор SHA1 Сообщение Дата
Narcis Beleuzu 3c50127358 Merge mozilla-central to autoland. a=merge CLOSED TREE 2019-06-05 00:51:07 +03:00
Nihanth Subramanya 203396c6e0 Bug 1555562 - Make sure LocalStorageManager::PrecacheStorage() passes in the real storage principal. r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D33559

--HG--
extra : moz-landing-system : lando
2019-06-04 21:13:40 +00:00
Jan Varga 67c1136dd9 Bug 1556217 - LSNG: Add a test for large items; r=asuth, smaug
Differential Revision: https://phabricator.services.mozilla.com/D33417
2019-06-02 08:00:25 +02:00
Jan Varga c6f87cb635 Bug 1540401 - Backout Part 3: Convert MOZ_DIAGNOSTIC_ASSERT back to MOZ_ASSERT since bug 1541772 hasn't been fixed yet; r=asuth 2019-06-04 09:59:11 +02:00
Jan Varga 65f92e054f Bug 1552428 - LSNG: Datastore::PrivateBrowsingClear uses wrong delta for usage updating; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D31605
2019-05-17 10:30:19 +02:00
Razvan Maries 7afbe4a8bf Backed out changeset 01dd2842bbaa (bug 1552428) for ES Lint failure. CLOSED TREE 2019-05-31 18:07:15 +03:00
Jan Varga 673d464ca1 Bug 1552428 - LSNG: Datastore::PrivateBrowsingClear uses wrong delta for usage updating; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D31605
2019-05-17 10:30:19 +02:00
Jan Varga 197c57d894 Bug 1546723 - Followup fix: Convert MOZ_DIAGNOSTIC_ASSERT back to MOZ_ASSERT since bug 1541775 hasn't been fixed yet; r=asuth 2019-05-30 21:34:11 +02:00
Jan Varga cce54f42f2 Bug 1546723 - Part 7: Fix ordering of items in special cases; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D31202
2019-05-15 06:11:11 +02:00
Jan Varga f122f3cf74 Bug 1546723 - Part 6: Mark snapshot as dirty if the hasOtherProcessObservers flag changes; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D31201
2019-05-15 06:11:11 +02:00
Jan Varga 55c0e5ec44 Bug 1546723 - Part 5: Generalize code for getting datastores; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D31200
2019-05-15 06:11:11 +02:00
Jan Varga b5acd8a9aa Bug 1546723 - Part 4: Use a write optimizer in LSSnapshot; r=asuth
This patch adds a write optimizer to LSSnapshot. The optimizer is only used when
there are no observers for other content processes.

Differential Revision: https://phabricator.services.mozilla.com/D31199
2019-05-15 06:11:11 +02:00
Jan Varga 46fee7012e Bug 1546723 - Part 3: Change GetSnapshotInitInfo to deal with load info only; r=asuth
This patch renames GetSnapshotInitInfo to GetSnapshotLoadInfo and removes some arguments that are not directly related to load info.

Differential Revision: https://phabricator.services.mozilla.com/D31198
2019-05-15 06:11:10 +02:00
Jan Varga 70f70b482a Bug 1546723 - Part 2: Make it more clear that checkpointing also notifies observers; r=asuth
This patch renames the Checkpoint IPC message to CheckpointAndNotify. Other structures used by checkpointing are renamed too. Datastore methods SetItem/RemoveItem/Clear no longer call NotifyObservers, it's now up to RecvCheckpointAndNotify to call it.

Differential Revision: https://phabricator.services.mozilla.com/D31197
2019-05-15 06:11:10 +02:00
Jan Varga a74b30fb4c Bug 1546723 - Part 1: Convert WriterOptimizer to a generic reusable class; r=asuth
This patch creates a new generic class LSWriteOptimizer which can be used with any value type for specific write optimizations either on the parent side or the child side.

Differential Revision: https://phabricator.services.mozilla.com/D31196
2019-05-15 06:11:10 +02:00
Ehsan Akhgari 98960a9c41 Bug 1554361 - Move the high-level storage access check APIs to mozilla/StorageAccess.h; r=baku
Differential Revision: https://phabricator.services.mozilla.com/D32556

--HG--
extra : moz-landing-system : lando
2019-05-27 14:06:49 +00:00
Jan Varga c673cb342d Bug 1540401 - Backout Part 2: Convert MOZ_DIAGNOSTIC_ASSERT back to MOZ_ASSERT since bug 1541775 hasn't been fixed yet; r=asuth 2019-05-23 10:26:20 +02:00
Dorel Luca 60706fc799 Merge mozilla-inbound to mozilla-central. a=merge 2019-05-18 13:25:28 +03:00
Gurzau Raul bc953c3503 Merge mozilla-central to autoland. a=merge CLOSED TREE 2019-05-18 00:46:18 +03:00
Tom Tung a3f0aa60d4 Bug 1514600 - P1 - Notify LS to cleanup the gUsages while storage initialization fails; r=janv
Differential Revision: https://phabricator.services.mozilla.com/D27502

--HG--
extra : moz-landing-system : lando
2019-04-29 10:49:58 +00:00
Jan Varga 869d5c854a Bug 1548847 - Invalidate LSDatabase xpcom-shutdown observer after removing it from the observer service; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D31293
2019-05-15 19:35:22 +02:00
Jan Varga 8c9f766a02 Bug 1540401 - Part 4: Convert MOZ_ASSERT to MOZ_DIAGNOSTIC_ASSERT to verify that bug 1541771 has been fixed; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D27494
2019-04-15 13:55:42 +02:00
Jan Varga e8e655e076 Bug 1540401 - Part 3: Convert MOZ_ASSERT to MOZ_DIAGNOSTIC_ASSERT to verify that bug 1541772 has been fixed; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D27493
2019-04-15 13:52:08 +02:00
Andrea Marchesini 99cbfe545e Bug 1551055 - StoragePrincipal should be supported by localStorage - part 3 - Validate storagePrincipal, r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D30947

--HG--
extra : moz-landing-system : lando
2019-05-14 05:49:58 +00:00
Andrea Marchesini dc7545548e Bug 1551055 - StoragePrincipal should be supported by localStorage - part 1, r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D30801

--HG--
extra : moz-landing-system : lando
2019-05-14 05:49:46 +00:00
Ciure Andrei f1dd75ca22 Backed out 3 changesets (bug 1551055) for causing xpcshell localStorage perma failures CLOSED TREE
Backed out changeset 21e44ad9c6df (bug 1551055)
Backed out changeset 8727e61ab69b (bug 1551055)
Backed out changeset d99a6769beb4 (bug 1551055)

--HG--
extra : rebase_source : 56f7fe5c54cd7e4109acce5074be1aba12e91086
2019-05-13 22:40:22 +03:00
Andrea Marchesini 1b54d6f1cd Bug 1551055 - StoragePrincipal should be supported by localStorage - part 3 - Validate storagePrincipal, r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D30947

--HG--
extra : moz-landing-system : lando
2019-05-13 18:45:12 +00:00
Andrea Marchesini e1b74991fb Bug 1551055 - StoragePrincipal should be supported by localStorage - part 1, r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D30801

--HG--
extra : moz-landing-system : lando
2019-05-13 18:42:36 +00:00
Jan Varga eef773ad6c Bug 1549654 - LSNG: Compress specific values during migration; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D30181
2019-05-07 12:54:02 +02:00
Jan Varga e25844ad71 Bug 1548788 - LSNG: Datastore preparation doesn't have to create new origin directories if they don't exist; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29822
2019-05-03 15:03:54 +02:00
Jan Varga ea67826b85 Bug 1547688 - LSNG: Preloading can use gUsages hash table to quickly finish if there's nothing to preload; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29194
2019-04-29 14:23:55 +02:00
Jan Varga c260fbaf28 Bug 1540777 - LSNG: Move creation of empty databases to the connection thread; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29134
2019-04-29 04:42:37 +02:00
Jan Varga 2ffbce35b7 Bug 1513937 - LSNG: Compress specific values; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29140
2019-04-29 06:10:42 +02:00
Jan Varga 6360443a3b Bug 1546310 - LSNG: Parent process should store values in UTF8; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29139
2019-04-29 06:09:42 +02:00
Jan Varga d3494ff018 Bug 1547454 - LSNG: Create a new C++ class for local storage values; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29138
2019-04-29 06:05:56 +02:00
Jan Varga 0ef08f3c51 Bug 1547452 - LSNG: Refactor Datastore::GetSnapshotInitInfo using a switch statement; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29137
2019-04-29 06:05:55 +02:00
Jan Varga d7c902c239 Bug 1542669 - LSNG: GetItem, SetItem, RemoveItem should pass the key when creating a new snapsot; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29136
2019-04-09 06:18:29 +02:00
Ryan VanderMeulen 4f044a29d2 Backed out 8 changesets (bug 1513937, bug 1546310, bug 1548788, bug 1547688, bug 1547452, bug 1540777, bug 1542669, bug 1547454) for causing bug 1549362.
Backed out changeset 8dca7df29492 (bug 1548788)
Backed out changeset 688f361e8bb6 (bug 1547688)
Backed out changeset b5d8d57838a3 (bug 1540777)
Backed out changeset d1bd31177b14 (bug 1513937)
Backed out changeset df97dfbb526a (bug 1546310)
Backed out changeset ade08d6dc361 (bug 1547454)
Backed out changeset b622431054b7 (bug 1547452)
Backed out changeset ad73e5604411 (bug 1542669)
2019-05-06 09:02:54 -04:00
Jan Varga 2820fe9cc8 Bug 1548788 - LSNG: Datastore preparation doesn't have to create new origin directories if they don't exist; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29822
2019-05-03 15:03:54 +02:00
Jan Varga 0d5ae59a7b Bug 1547688 - LSNG: Preloading can use gUsages hash table to quickly finish if there's nothing to preload; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29194
2019-04-29 14:23:55 +02:00
Jan Varga f961342025 Bug 1540777 - LSNG: Move creation of empty databases to the connection thread; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29134
2019-04-29 04:42:37 +02:00
Jan Varga 12fd20045f Bug 1513937 - LSNG: Compress specific values; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29140
2019-04-29 06:10:42 +02:00
Jan Varga 120ed0037a Bug 1546310 - LSNG: Parent process should store values in UTF8; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29139
2019-04-29 06:09:42 +02:00
Jan Varga f482d3216d Bug 1547454 - LSNG: Create a new C++ class for local storage values; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29138
2019-04-29 06:05:56 +02:00
Jan Varga 55c70603a2 Bug 1547452 - LSNG: Refactor Datastore::GetSnapshotInitInfo using a switch statement; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29137
2019-04-29 06:05:55 +02:00
Jan Varga 128af24b07 Bug 1542669 - LSNG: GetItem, SetItem, RemoveItem should pass the key when creating a new snapsot; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D29136
2019-04-09 06:18:29 +02:00
Jan Varga 827b401e30 Bug 1513915 - Followup patch to increase requesttimeoutfactor for test_snapshotting.js; r=asuth 2019-05-03 18:10:11 +02:00
Jan Varga 864dcf0703 Bug 1513915 - LSNG: LoadItem could return more items (up to the prefill limit); r=asuth,jld
Differential Revision: https://phabricator.services.mozilla.com/D26476
2019-04-08 10:56:19 +02:00
Jan Varga 478be0531a Bug 1540401 - Part 2: Convert MOZ_ASSERT to MOZ_DIAGNOSTIC_ASSERT to verify that bug 1541775 has been fixed; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D27492
2019-04-15 13:49:35 +02:00
Jan Varga 1a8201461c Bug 1540401 - Part 1: Convert MOZ_ASSERT to MOZ_DIAGNOSTIC_ASSERT to verify that bug 1541972 has been fixed; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D27491
2019-04-15 13:46:06 +02:00
Jan Varga 4d4622f55f Bug 1546305 - LSNG: Add temporary support for downgrading; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D28800
2019-04-25 11:25:52 +02:00
Jan Varga bb200f7d87 Bug 1541771 - LSNG: Don't cache usage in InitOrigin if it's not for temporary storage initialization; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D27490
2019-04-15 13:35:38 +02:00
Jan Varga f968189930 Bug 1535221 - Dead lock with a11y's mscom and mozilla::dom::LSObject; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D27463
2019-04-15 05:04:02 +02:00
Jan Varga d50956f778 Bug 1542706 - LSNG: Don't close database if there's a snapshot registered; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D27437
2019-04-13 17:59:55 +02:00
Jan Varga 8120eb21d7 Backout Bug 1540401 - Part 1: Convert MOZ_ASSERT to MOZ_DIAGNOSTIC_ASSERT to verify that bug 1541972 has been fixed; r=asuth 2019-04-16 20:05:49 +02:00
Jan Varga 91e4dfb638 Bug 1540401 - Part 1: Convert MOZ_ASSERT to MOZ_DIAGNOSTIC_ASSERT to verify that bug 1541972 has been fixed; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D27491
2019-04-15 13:46:06 +02:00
Jan Varga 31b9a4462c Bug 1542155 - LSNG: Convert MOZ_ALWAYS_TRUE(SendFinish()) to MOZ_DIAGNOSTIC_ALWAYS_TRUE(SendFinish()); r=asuth 2019-04-05 16:46:59 +02:00
Jan Varga 2927a7377f Bug 1543209 - LSNG: Detect missing unregister calls for live datastores using CheckedUnsafePtr; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D26826
2019-04-09 23:56:17 +02:00
Jan Varga 06dba23590 Bug 1542475 - LSNG: Potential double closing of datastores; r=asuth 2019-04-06 12:23:14 +02:00
Yaron Tausky e8af6c032a Bug 1539538 - Introduce UnsafePtr r=froydnj,janv
This commit adds a smart pointer class that verifies that no dangling
pointers remain after the pointee went out of scope. This verification is
opt-in and can be controlled both statically and dynamically by the pointee.

Differential Revision: https://phabricator.services.mozilla.com/D25200

--HG--
extra : moz-landing-system : lando
2019-04-09 14:41:57 +00:00
Sylvestre Ledru 03fc65347c Bug 1542146 - Apply the change with the option StatementMacros from clang-format-8 r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D26280

--HG--
extra : moz-landing-system : lando
2019-04-05 21:42:17 +00:00
Jan Varga caa68dc186 Bug 1542104 - LSNG: Incorrect usage calculation of archived data; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D26269
2019-04-05 06:15:21 +02:00
Jan Varga 4286c73927 Bug 1540381 - LSNG: Result of SendRequestAllowToClose call is not checked; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D25703
2019-04-02 05:44:56 +02:00
Ciure Andrei 4116e08315 Merge inbound to mozilla-central. a=merge 2019-04-04 07:34:14 +03:00
Ciure Andrei ec1fe36f87 Backed out changeset 97d88752079f (bug 1540401) for causing a nightly startup crash a=backout 2019-04-04 04:45:08 +03:00
Daniel Varga f89113118b Merge mozilla-central to mozilla-inbound. a=merge 2019-04-03 09:18:15 +03:00
Daniel Varga 14dc5b7d8a Merge mozilla-inbound to mozilla-central. a=merge 2019-04-03 09:05:41 +03:00
Gerald Squelart e2d15a1cfb Bug 1429613 - Variant matcher callbacks renamed from `match` to `operator()` - r=froydnj
Mechanical change from Matcher::match(...) to Matcher::operator()(...).
This will now permit the use of generic lambdas, and facilitate the
implementation of multi-lambda match.

Differential Revision: https://phabricator.services.mozilla.com/D24889

--HG--
extra : moz-landing-system : lando
2019-04-02 11:53:47 +00:00
Jan Varga 8838c839de Bug 1540401 - LSNG: Convert most of MOZ_ASSERT to MOZ_DIAGNOSTIC_ASSERT; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D25549
2019-04-01 01:18:10 +02:00
Jan Varga 78e96d22bc Bug 1540189 - LSNG: Result of SendReady call is not checked; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D25423
2019-03-29 17:58:46 +01:00
Eden Chuang 72b79c6fbd Bug 1442778 - Add "chromeContext" parameter to console API and console service messages. r=smaug
1. Adding a new attribute chromeContext in ConsoleEvent
2. Adding a new boolean attribute isFromChromeContext in nsIConsoleMessage
3. Sending IsFromChromeContext to the parent process

Differential Revision: https://phabricator.services.mozilla.com/D23330

--HG--
extra : moz-landing-system : lando
2019-04-01 22:42:34 +00:00
Mark Banner dba6983e75 Bug 1415265 - Remove now unnecessary .eslintrc.js files or entries. r=mossop
Differential Revision: https://phabricator.services.mozilla.com/D23850

--HG--
extra : moz-landing-system : lando
2019-03-28 09:38:14 +00:00
Cosmin Sabou 78fc71e3c3 Backed out changeset 7fa7d6e6dedc (bug 1442778) for devtools failures on browser_webconsole_check_stubs_console_api.js CLOSED TREE 2019-03-26 20:27:55 +02:00
Csoregi Natalia 888d83038c Merge mozilla-central to autoland. CLOSED TREE 2019-03-26 19:45:08 +02:00
Eden Chuang 5e4df764d9 Bug 1442778 - Add "chromeContext" parameter to console API and console service messages. r=smaug
1. Adding a new attribute chromeContext in ConsoleEvent
2. Adding a new boolean attribute isFromChromeContext in nsIConsoleMessage
3. Sending IsFromChromeContext to the parent process

Differential Revision: https://phabricator.services.mozilla.com/D23330

--HG--
extra : moz-landing-system : lando
2019-03-26 15:18:20 +00:00
Ian Moody fe4fab15e3 Bug 1537776 - dom/ automated ESLint no-throw-literal fixes. r=asuth,mccr8
Result of running:
$ mach eslint -funix dom/ | sed -Ee 's/:.+//' - | xargs sed -E \
    -e 's/throw ((["`])[^"]+\2);/throw new Error(\1);/g' \
    -e 's/throw ((["`])[^"]+\2 \+ [^ ";]+);/throw new Error(\1);/g' \
    -e 's/throw \(/throw new Error(/g' -i

Differential Revision: https://phabricator.services.mozilla.com/D24369

--HG--
extra : moz-landing-system : lando
2019-03-25 16:03:38 +00:00
Jan Varga 44461f8eff Bug 1535221 - Add more robust logging including more detailed logging for CheckClosingDatastore and DirectoryOpenPending state; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D24423
2019-03-21 21:08:00 +01:00
Gurzau Raul b9149db16e Merge mozilla-central to inbound. a=merge CLOSED TREE 2019-03-26 11:56:14 +02:00
Jan Varga 8eef834961 Bug 1533789 - LSRequestBase::Finish is not called in some edge cases; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D24649
2019-03-24 15:02:05 +01:00
Jan Varga 1ce29b4c3b Bug 1535221 - Add infrastructure for hang debugging; r=asuth
This patch adds a timer for synchronous local storage requests. Once the timer
fires the request is canceled. The parent reports debugging information upon receiving cancellation.

Differential Revision: https://phabricator.services.mozilla.com/D24006
2019-03-19 12:23:16 +01:00
Jan Varga 1678e32e36 Bug 1535995 - Quick followup patch to fix an ESlint failure; r=asuth 2019-03-18 18:12:09 +01:00
Jan Varga 9db88adebf Bug 1535995 - Check that group information is up to date; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D23822
2019-03-18 07:14:26 +01:00
Sebastian Hengst 78d58dd656 Bug 1535619 - add meta information to create bugs for files in dom/localstorage/ in 'Core :: DOM: Web Storage' r=janv
Differential Revision: https://phabricator.services.mozilla.com/D23670

--HG--
extra : moz-landing-system : lando
2019-03-15 14:01:58 +00:00
Sylvestre Ledru 4aa92e3091 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D22514
2019-03-13 10:19:06 +01:00
Jan Varga 559e8234e4 Bug 1534208 - LSNG: DOM File thread and PBackground child for it must be created as soon as possible; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D22976
2019-03-11 15:35:04 +01:00
Jan Varga 8b4670b550 Bug 1533541 - dom/localstorage/test/unit/test_groupLimit.js fails with LSNG enabled; r=asuth
Reviewers: asuth

Reviewed By: asuth

Bug #: 1533541

Differential Revision: https://phabricator.services.mozilla.com/D22599

--HG--
extra : rebase_source : fd352191fec915b68bb9161e1de7c89a0522be52
2019-03-07 20:46:46 -05:00
Jan Varga c2058d3bc4 Bug 1526891 - Part 10: Fix a content process leak by closing databases at xpcom-shutdown; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D20919
2019-02-23 17:19:35 +01:00
Jan Varga 6b68f4dc07 Bug 1526891 - Part 5: Allow calling NextGenLocalStorageEnabled on any thread in the parent process; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D20914
2019-02-23 17:06:40 +01:00
Jan Varga ea4f36b735 Bug 1526615 - Part 3: Avoid main thread during origin clearing; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D19284
2019-02-10 10:20:14 +01:00
Jan Varga 62cb092a89 Bug 1526615 - Part 2: Implement GenerateOriginKey2 which can be used on any thread; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D19283
2019-02-10 10:20:12 +01:00
Jan Varga 1ee1cd1c2d Bug 1517089 - Part 17: Avoid main thread during LSRequestBase/LSSimpleRequestBase processing; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D19214
2019-02-08 21:02:28 +01:00
Jan Varga f150c82b06 Bug 1517089 - Part 14: Use ClientManagerService for client validation; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D19208
2019-02-08 21:02:14 +01:00
Jan Varga 2e11851013 Bug 1517089 - Part 13: Use separate IPC params and response for datastore preloading; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D19207
2019-02-08 21:02:11 +01:00
Jan Varga 993ecafb04 Bug 1517089 - Part 11: Verify principalInfo before creating any parent actors; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D19205
2019-02-08 21:02:03 +01:00
Jan Varga 7fa5c4663a Bug 1517089 - Part 7: Pass originKey through IPC and get privateBrowsingId directly from ContentPrincipalInfo; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D19201
2019-02-08 21:01:31 +01:00
Yaron Tausky 43054fe975 Bug 1516277 - Add local execution mode to nsThread r=janv,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D21241

--HG--
extra : moz-landing-system : lando
2019-03-06 16:26:07 +00:00
Gurzau Raul d5392415e2 Backed out changeset 44d83d32e254 (bug 1516277) for failing at /test/unit/test_eviction.js on a CLOSED TREE. 2019-03-06 17:50:28 +02:00
Yaron Tausky 3aa9896ebc Bug 1516277 - Add local execution mode to nsThread r=janv,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D21241

--HG--
extra : moz-landing-system : lando
2019-03-06 13:53:16 +00:00
Boris Zbarsky 9c5da5f234 Bug 1489308 part 9. Remove now-unused wyciwyg bits. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D17327

--HG--
rename : dom/html/test/browser_refresh_wyciwyg_url.js => dom/html/test/browser_refresh_after_document_write.js
rename : dom/html/test/file_refresh_wyciwyg_url.html => dom/html/test/file_refresh_after_document_write.html
extra : moz-landing-system : lando
2019-02-28 01:09:48 +00:00
Sylvestre Ledru 41d1d79094 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D19663

--HG--
extra : moz-landing-system : lando
2019-02-15 08:15:57 +00:00
Jan Varga 38f8064388 Bug 1517089 - Part 6: Use BackgroundParent::GetChildID (which doesn't need releasing content parent on the main thread) for getting content parent id; r=asuth 2019-02-07 19:51:27 +01:00
Jan Varga 5302b36c41 Bug 1517089 - Part 5: Move storage service initialization to InitializeLocalStorage; r=asuth 2019-02-07 19:51:22 +01:00
Jan Varga 01b23e7ba8 Bug 1517089 - Part 4: Send an async IPC message instead of dispatching a runnable to the PBackground thread when clearing private browsing; r=asuth 2019-02-07 19:51:16 +01:00
Jan Varga f0a5d09ef7 Bug 1517089 - Part 3: Move observer registration to InitializeLocalStorage; r=asuth 2019-02-07 19:51:12 +01:00
Jan Varga ed1d36b2c0 Bug 1517089 - Part 2: Move pref initialization to InitializeLocalStorage; r=asuth 2019-02-07 19:51:07 +01:00
Jan Varga 913fd9266d Bug 1517089 - Part 1: Introduce InitializeLocalStorage and call it in nsLayoutStatics::Initialize; r=asuth 2019-02-07 19:50:57 +01:00
Jan Varga d0270542f0 Bug 1525291 - LSNG: Chrome observer notifications for session storage are not distributed to content processes; r=asuth,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D18809
2019-02-06 06:09:57 +01:00
Oana Pop Rus f9cf535efc Backed out changeset 04eecadabb48 (bug 1525291) for build bustages at build/src/obj-firefox/ipc/ipdl/PSessionStorageObserverChild.cpp on a CLOSED TREE 2019-02-07 11:33:00 +02:00
Jan Varga 93f5a88427 Bug 1525291 - LSNG: Chrome observer notifications for session storage are not distributed to content processes; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D18809
2019-02-06 06:09:57 +01:00
Kris Maglione e930b89c34 Bug 1514594: Part 3 - Change ChromeUtils.import API.
***
Bug 1514594: Part 3a - Change ChromeUtils.import to return an exports object; not pollute global. r=mccr8

This changes the behavior of ChromeUtils.import() to return an exports object,
rather than a module global, in all cases except when `null` is passed as a
second argument, and changes the default behavior not to pollute the global
scope with the module's exports. Thus, the following code written for the old
model:

  ChromeUtils.import("resource://gre/modules/Services.jsm");

is approximately the same as the following, in the new model:

  var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");

Since the two behaviors are mutually incompatible, this patch will land with a
scripted rewrite to update all existing callers to use the new model rather
than the old.
***
Bug 1514594: Part 3b - Mass rewrite all JS code to use the new ChromeUtils.import API. rs=Gijs

This was done using the followng script:

https://bitbucket.org/kmaglione/m-c-rewrites/src/tip/processors/cu-import-exports.jsm
***
Bug 1514594: Part 3c - Update ESLint plugin for ChromeUtils.import API changes. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D16747
***
Bug 1514594: Part 3d - Remove/fix hundreds of duplicate imports from sync tests. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16748
***
Bug 1514594: Part 3e - Remove no-op ChromeUtils.import() calls. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16749
***
Bug 1514594: Part 3f.1 - Cleanup various test corner cases after mass rewrite. r=Gijs
***
Bug 1514594: Part 3f.2 - Cleanup various non-test corner cases after mass rewrite. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16750

--HG--
extra : rebase_source : 359574ee3064c90f33bf36c2ebe3159a24cc8895
extra : histedit_source : b93c8f42808b1599f9122d7842d2c0b3e656a594%2C64a3a4e3359dc889e2ab2b49461bab9e27fc10a7
2019-01-17 10:18:31 -08:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Tom Tung a4b7f90f3f Bug 1436188 - Add telemetry probes to collect the number of failures during the QuotaManager initialization; r=asuth, data-review=chutten
This patch uses categorical keyed Historgram to collect data. While the key is
used to determine whether is it an external error or an internal error (Note:
the external error is referred to low level failure, for example: database
corrupt, OS API errors, ... etc; the internal error is referred to errors, like:
not handle file properly, unexpected filenames, ... etc), the labels for
categorical indicates where the error happens.
Furthermore, this patch make QuotaManager keep traversing the profile even if
an error happens so that we can get more information in the telemetry data.
Please note that these things should only happen in the Nightly Channel.

Differential Revision: https://phabricator.services.mozilla.com/D15908

--HG--
extra : moz-landing-system : lando
2019-01-17 17:12:27 +00:00
Emilio Cobos Álvarez d2ed260822 Bug 1517241 - Rename nsIDocument to mozilla::dom::Document. r=smaug
Summary: Really sorry for the size of the patch. It's mostly automatic
s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to
add the right namespacing and such.

Overall it's not a very interesting patch I think.

nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and
nsIDocumentInlines.h into DocumentInlines.h.

I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it.

While fixing up some of the bits I also removed some unneeded OwnerDoc() null
checks and such, but I didn't do anything riskier than that.
2019-01-03 17:48:33 +01:00
Sylvestre Ledru cccdda3c2a Bug 1516555 - Reformat everything to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D15426

--HG--
extra : moz-landing-system : lando
2018-12-28 15:48:06 +00:00
Gurzau Raul 55697e5bce Merge inbound to mozilla-central. a=merge 2018-12-21 18:36:36 +02:00
Mark Banner 925ccf2751 Bug 1515605 - Enable ESLint for dom/localstorage (manual changes). r=janv
Differential Revision: https://phabricator.services.mozilla.com/D15073

--HG--
extra : moz-landing-system : lando
2018-12-21 10:13:00 +00:00
Mark Banner e802d90ab3 Bug 1515605 - Enable ESLint for dom/localstorage (automatic changes). r=janv
Differential Revision: https://phabricator.services.mozilla.com/D15072

--HG--
extra : moz-landing-system : lando
2018-12-21 10:12:45 +00:00
Jan Varga 9f045e03d5 Bug 1513892 - Part 2: Cache usage in a standalone file; r=asuth
This patch significantly speedups origin initialization by having a special file
for current data usage.
2018-12-21 06:26:36 +01:00
Jan Varga 630b46cb1d Bug 1513892 - Part 1: Cache usage in the database table; r=asuth
This patch slightly speedups origin initialization by having a special column in
the database table for current data usage.
This patch also fixes a problem with length computation of some unicode strings.
2018-12-21 06:26:25 +01:00
Narcis Beleuzu 7cfde3000c Merge inbound to mozilla-central. a=merge 2018-12-20 23:56:42 +02:00
Jan Varga 2e452b2b07 Bug 1505798 - The used storage space for saved cookies,site data, cache displayed in about:preferences is abnormal after enabling NextGen Storage; r=asuth
This patch fixes an oversight when an important hashtable lookup was only done
in debug builds.
2018-12-20 19:20:36 +01:00
Alex Gaynor 55e3f21b2b Bug 1515437 - mark several IPC methods as final; r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D15011

--HG--
extra : moz-landing-system : lando
2018-12-19 21:46:49 +00:00
Jan Varga 849998a8e0 Bug 1513859 - CPOWs can still cause a hang with LSNG enabled; r=asuth 2018-12-19 12:38:23 +01:00
Jan Varga f561d97124 Bug 1513892 - Followup for Part 2; r=asuth
Add a comment about not being able to read 64-bit integers.
2018-12-21 06:39:45 +01:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Andrew Sutherland 6c6e230a77 Bug 1286798 - Part 53: Review code comments; r=janv,mrbkap,mccr8 2018-11-05 14:04:39 -05:00
Jan Varga 35d317c919 Bug 1286798 - Part 52: Rework tests to use async functions; r=asuth 2018-11-29 21:50:01 +01:00
Jan Varga 4220031bba Bug 1286798 - Part 51: Add tests for archive and shadow database clearing; r=asuth 2018-11-29 21:49:58 +01:00
Jan Varga ccca35f7f3 Bug 1286798 - Part 50: Add support for clearing of the archive and shadow database; r=asuth 2018-11-29 21:49:55 +01:00
Jan Varga 03fc857fab Bug 1286798 - Part 46: Add a pref for database shadowing; r=asuth 2018-11-29 21:49:43 +01:00
Jan Varga 3f301fd6c0 Bug 1286798 - Part 45: Delay flushing to disk using a timer; r=asuth
This improves performance even more by grouping database operations from multiple checkpoints and possibly from multiple processes.
2018-11-29 21:49:40 +01:00
Jan Varga cf023d79b4 Bug 1286798 - Part 44: Switch Connection to use WriteOptimizer too; r=asuth
This eliminates some code duplication.
2018-11-29 21:49:37 +01:00
Jan Varga 1e027be676 Bug 1286798 - Part 43: Coalesce database operations before they are applied to disk; r=asuth
This avoids persistence to disk in many cases since sites aften do setItem/removeItem for the same key in one JS function.
2018-11-29 21:49:34 +01:00
Jan Varga 3177670987 Bug 1286798 - Part 42: Implement snapshot reusing; r=asuth
This improves performance by keeping snapshots around for some time if there are no changes done by other processes. If a snapshot is not destroyed immediately after getting into the stable state then there's a chance that it won't have to be synchronously created again when a new opeartion is requested.
2018-11-29 21:49:31 +01:00
Jan Varga 150cf2ce62 Bug 1286798 - Part 41: Implement QuotaClient::AbortOperationsForProcess; r=asuth
Needed for snapshot reusing.
2018-11-29 21:49:27 +01:00
Jan Varga 8d2b3b583d Bug 1286798 - Part 39: Reduce number of hash lookups; r=asuth 2018-11-29 21:49:20 +01:00
Jan Varga f2c1577652 Bug 1286798 - Part 38: Cache items in an array; r=asuth
Items are now cached also in an array (besides a hashtable). This gives us very fast snapshot initizilization for datastores that fit into the prefill limit. String buffers are reference counted, so memory footprint is only affected by the size of nsString.
This patch also introduces a WriteOptimizer which is an abstraction for collecting, coalescing and applying write operations.
2018-11-29 21:49:17 +01:00
Jan Varga 05662ca09e Bug 1286798 - Part 37: Always preallocate quota when initializing a snapshot; r=asuth
Besides always preallocating quota we now also preallocate more. This mitigates number of additional sync calls.
2018-11-29 21:49:14 +01:00
Jan Varga 5809f14bbd Bug 1286798 - Part 36: Allow snapshot initialization to a specific load state; r=asuth
Before this patch, it was only possible to initialize a snapshot to the Partial state or AllOrderedItems state. Now there's a third state AllOrderedKeys.
This improves performance by eliminating sync calls to parent process when we know nothing about a key in content process (in that case we have to use a sync call to the parent process to see if there's a value for it).
With this patch we always try to send all keys to content when a snapshot is being initialized. For this to work efficiently, we cache the size of all keys.
Having cached size of all keys also allows us to just iterate the mValues hashtable when the size of keys is bigger than snapshot prefill threshold (instead of iterating over the mKeys array and joining with mValues for each particular key).
There's some additional cleanup in snapshot info construction and Datastore::SetItem/RemoveItem/Clear methods.
2018-11-29 21:49:10 +01:00
Jan Varga ec6ab2e194 Bug 1286798 - Part 35: Implement database shadowing; r=asuth,janv
This adds synchronization to the global database used by previous local storage implementation.

This patch was enhanced by asuth to bind attached database path.
Places has shown that argument binding is necessary.  (Profiles may include usernames in their path which can have cool emoji and such.)
2018-11-29 21:49:07 +01:00
Jan Varga 4afa59b9c8 Bug 1286798 - Part 34: Queue database operations until update batch ends; r=asuth
This avoids dispatching to the connection thread for every database operation and paves a way for database shadowing.
2018-11-29 21:49:04 +01:00
Jan Varga 06d1c01932 Bug 1286798 - Part 33: Restrict localStorage from being available on some pages; r=asuth
This matches the old implementation. localStorage shouldn't be available on some pages, for example about:home.
2018-11-29 21:49:01 +01:00
Jan Varga d87888fe25 Bug 1286798 - Part 31: Support for lazy loading of items; r=asuth,mrbkap,mccr8
There's now an upper limit for snapshot prefilling. The value is configurable and is currently set to 4096 bytes.
Snapshots can operate in multiple modes depending on if all items have been loaded or all keys have been received. This should provide the best performance for each specific state.
This patch also adds support for creating explicit snapshots which can be used for testing.
2018-11-29 21:48:54 +01:00
Jan Varga 34cd5113f1 Bug 1286798 - Part 30: Preserve key order when sending items to a content process; r=asuth
Keys needs to be redundantly stored in an array, so we can construct identical hashtable of values in a content process.
2018-11-29 21:48:51 +01:00
Jan Varga c4f55013cf Bug 1286798 - Part 29: Implement implicit snapshotting of databases; r=asuth,mccr8
This improves performance a lot in cases when multiple operations are invoked by a single JS function (number of sync IPC calls is reduced to a minimum). It also improves correctness since changes are not visible to other content processes until a JS function finishes.
The patch implements core infrastructure, all items are sent to content when a snapshot is initialized and everything is fully working. However, sending of all items at once is not optimal for bigger databases. Support for lazy loading of items is implemented in a following patch.
2018-11-29 21:48:47 +01:00
Jan Varga 54be9b7307 Bug 1286798 - Part 28: Add more QuotaClient::IsShuttingDownOnBackgroundThread() and MayProceed() checks; r=asuth
The shutdown and actor destroyed flag is now checked after each dispatch.
2018-11-29 21:48:44 +01:00
Jan Varga 1812608353 Bug 1286798 - Part 27: Share database actors; r=asuth
If a database actor already exists for given origin, reuse it instead of creating a new one. This improves memory footprint a bit and also eliminates some round trips to the parent process.
2018-11-29 21:48:41 +01:00
Jan Varga 0649224345 Bug 1286798 - Part 26: Implement a lazy data migration from old webappsstore.sqlite; r=asuth,janv
This patch was enhanced by asuth to bind attached database path.
Places has shown that argument binding is necessary.  (Profiles may include usernames in their path which can have cool emoji and such.)
2018-11-29 21:48:38 +01:00
Jan Varga 7981be440b Bug 1286798 - Part 25: Add checks for the group and global limit; r=asuth 2018-11-29 21:48:34 +01:00
Jan Varga 6e40a9dccb Bug 1286798 - Part 22: Add support for preloading of datastores; r=asuth
Datastores are preloaded only for content principals. The preloading is triggered as soon as possible to lower the chance of blocking the main thread in content process. If there is no physical database on disk for given origin, datastore is not created. Preloaded datastores are kept alive for 20 seconds.
2018-11-29 21:48:25 +01:00