Commit Graph

697 Commits

Author SHA1 Message Date
Simon Giesecke
2e68c75bb1 Bug 1626973 - Add assertions for result of MaybeUpdateSize. r=janv,dom-workers-and-storage-reviewers
Depends on D69580

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

--HG--
extra : moz-landing-system : lando
2020-04-03 16:16:50 +00:00
Tom Tung
02b4a20039 Bug 1626846 - Disable useDOSDevicePathSyntax for QuotaStorage on Windows; r=dom-workers-and-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D69318

--HG--
extra : moz-landing-system : lando
2020-04-06 09:28:35 +00:00
Tom Tung
3d69caa161 Bug 1536796 - P6 - Changes on dom/quota unit test to verify the fix; r=dom-workers-and-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D60872

--HG--
extra : moz-landing-system : lando
2020-04-01 07:52:33 +00:00
Tom Tung
94e4123950 Bug 1536796 - P3 - Use QM_NewLocalFile in QM and its clients; r=janv,dom-workers-and-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D67875

--HG--
extra : moz-landing-system : lando
2020-04-01 07:26:27 +00:00
Tom Tung
4debe01abb Bug 1536796 - P1 - Introduce a flag (useDOSDevicePathSyntax) to nsILocalFileWin and a method (QM_NewLocalFile) to QuotaCommon; r=janv,dom-workers-and-storage-reviewers,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D67873

--HG--
extra : moz-landing-system : lando
2020-04-01 07:26:27 +00:00
André Bargull
14ca007916 Bug 1625138 - Part 41: Remove no longer needed includes for mozilla/TypeTraits. r=froydnj
Also adds missing includes in some files, these were previously only transivitely
included through mozilla/TypeTraits.h.

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

--HG--
extra : moz-landing-system : lando
2020-03-28 16:00:09 +00:00
André Bargull
ebec34a898 Bug 1625138 - Part 16: Replace mozilla::IsIntegral with std::is_integral. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D68371

--HG--
extra : moz-landing-system : lando
2020-03-28 13:57:15 +00:00
André Bargull
9ad58ea608 Bug 1625138 - Part 13: Replace mozilla::IsUnsigned with std::is_unsigned. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D68368

--HG--
extra : moz-landing-system : lando
2020-03-28 13:57:14 +00:00
Jan Varga
d371cf7402 Bug 1624880 - Fix quota/test/unit/upgrades tests when LSNG is disabled by default; r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D68211

--HG--
extra : moz-landing-system : lando
2020-03-26 19:20:56 +00:00
Simon Giesecke
58d0171406 Bug 1620632 - Ensure nsTArray_Impl only declares a copy-constructor/assignment operator if E is copy-constructible. r=froydnj
To correctly implement this, it must be known on instantiation whether E is
copy-constructible, which is not the case if only a forward declaration is
available. This can be resolved either by making sure a full definition of E is
available, which is preferable. But in cases where this is not (easily) possible,
the information can be explicitly provided by the MOZ_DECLARE_COPY_CONSTRUCTIBLE
and MOZ_DECLARE_NON_COPY_CONSTRUCTIBLE macros. In particular, declarations for
IPDL-declared types are added to nsTArray.h itself, like it was already done
for MOZ_DECLARE_RELOCATE_USING_MOVE_CONSTRUCTOR.

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

--HG--
extra : moz-landing-system : lando
2020-03-20 17:13:51 +00:00
Simon Giesecke
7e9a7de895 Bug 1620632 - Rename confusingly named types/macros for relocation handling of nsTArray. r=froydnj
Specifically, this renames
* nsTArray_CopyChooser to nsTArray_RelocationStrategy
* the Copy template argument of nsTArray_base to RelocationStrategy
* nsTArray_CopyWithConstructors to nsTArray_RelocateUsingMoveConstructor
* nsTArray_CopyWithMemutils to nsTArray_RelocateUsingMemutils
* DECLARE_USE_COPY_CONSTRUCTORS to MOZ_DECLARE_RELOCATE_USING_MOVE_CONSTRUCTOR

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

--HG--
extra : moz-landing-system : lando
2020-03-20 17:04:27 +00:00
Jan Varga
188bead06b Bug 1619592 - Update selected operations to not implicitly initialize storage; r=dom-workers-and-storage-reviewers,sg
All initialization related operations, the clear all operation and reset
operations now fail if storage is not initialized. All other operations make
sure storage is initialized by setting the mNeedsStorageInit flag.
DirectoryWork() for these operations now assert that storage is initialized.

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

--HG--
extra : moz-landing-system : lando
2020-03-17 13:07:23 +00:00
Jan Varga
e5f5d6eb65 Bug 1619592 - Remove aResetAll param from nsIQuotaManagerService::ResetStoragesForPrincipal; r=dom-workers-and-storage-reviewers,sg
The aResetAll param has been removed from resetStoragesForPrincipal since
there's no use case for it right now (if there's a use case for it in future, it
should be handled by a separate method like resetOriginsByPrefix).

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

--HG--
extra : moz-landing-system : lando
2020-03-17 13:01:38 +00:00
Jan Varga
3cd7583a34 Bug 1619592 - Separate ResetOriginOp from ClearOriginOp; r=dom-workers-and-storage-reviewers,sg
ResetOriginOp has been separated from ClearOriginOp for better readibility of
code.

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

--HG--
extra : moz-landing-system : lando
2020-03-17 13:06:47 +00:00
Jan Varga
c0757a0c2c Bug 1619592 - Refactor client type checks using new Client::IsValidType method; r=dom-workers-and-storage-reviewers,sg
This patch moves client type checks to the parameter validation phase. The checks are now done using new Client::IsValidType method.

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

--HG--
extra : moz-landing-system : lando
2020-03-17 13:06:30 +00:00
Jan Varga
5cebbc21b1 Bug 1619592 - Refactor persistence type checks using new IsValidPersistenceType method; r=dom-workers-and-storage-reviewers,sg
This patch makes use of the IsValidPersistenceType function it adds at places where individual checks were done before. It also moves some checks to the parameter validation phase.

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

--HG--
extra : moz-landing-system : lando
2020-03-17 13:06:17 +00:00
Jan Varga
a87575bf55 Bug 1619592 - Rationalize PersistenceTypeTo* and PersistenceTypeFrom* methods; r=dom-workers-and-storage-reviewers,sg
Differential Revision: https://phabricator.services.mozilla.com/D65937

--HG--
extra : moz-landing-system : lando
2020-03-13 12:55:20 +00:00
Simon Giesecke
6223cfb160 Bug 1618121 - Make CheckedUnsafePtr a literal type and trivially copyable if checking is disabled, and add get member function. r=dom-workers-and-storage-reviewers,edenchuang
Differential Revision: https://phabricator.services.mozilla.com/D64302

--HG--
extra : moz-landing-system : lando
2020-03-12 15:04:18 +00:00
Tom Tung
130b9fec28 Bug 1619910 - P2 - Collect the success rates of upgrades from indexedDB/ and storage/persistent/ directory; r=janv,dom-workers-and-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D65469

--HG--
extra : moz-landing-system : lando
2020-03-11 12:52:04 +00:00
Tom Tung
f73f17be94 Bug 1619910 - P1 - Change MaybeUpgradeFrom* to UpgradeFrom*; r=janv,dom-workers-and-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D65523

--HG--
extra : moz-landing-system : lando
2020-03-11 12:51:26 +00:00
Oana Pop Rus
e07c2cf135 Backed out 2 changesets (bug 1618121, bug 1617993) for build bustages in CheckedUnsafePtr.h on a CLOSED TREE
Backed out changeset 2658800d6c78 (bug 1617993)
Backed out changeset 6e0a1c83694c (bug 1618121)
2020-03-12 16:59:41 +02:00
Simon Giesecke
d29259a248 Bug 1618121 - Make CheckedUnsafePtr a literal type and trivially copyable if checking is disabled, and add get member function. r=dom-workers-and-storage-reviewers,edenchuang
Differential Revision: https://phabricator.services.mozilla.com/D64302

--HG--
extra : moz-landing-system : lando
2020-03-12 13:48:18 +00:00
Narcis Beleuzu
02dfadf8c9 Backed out 2 changesets (bug 1618121, bug 1617993) for assertion failure at nsTArray.h . CLOSED TREE
Backed out changeset e4d228335a49 (bug 1617993)
Backed out changeset b874484bdeb7 (bug 1618121)
2020-03-12 11:40:00 +02:00
Simon Giesecke
b118d306ad Bug 1618121 - Make CheckedUnsafePtr a literal type and trivially copyable if checking is disabled, and add get member function r=dom-workers-and-storage-reviewers,edenchuang
Differential Revision: https://phabricator.services.mozilla.com/D64302

--HG--
extra : moz-landing-system : lando
2020-03-10 15:50:16 +00:00
shindli
0b7c33c8d9 Backed out changeset 50af9d58c645 (bug 1619592) for causing build bustages in /builds/worker/checkouts/gecko/dom/quota/PersistenceType.cpp CLOSED TREE 2020-03-11 10:37:51 +02:00
Jan Varga
a415028a3c Bug 1619592 - Rationalize PersistenceTypeTo* and PersistenceTypeFrom* methods; r=dom-workers-and-storage-reviewers,sg
Differential Revision: https://phabricator.services.mozilla.com/D65937

--HG--
extra : moz-landing-system : lando
2020-03-11 08:08:46 +00:00
Mark Banner
15cfe23b88 Bug 1620542 - Automatically fix ESLint errors in .eslintrc.js files. r=mossop
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2020-03-07 10:09:44 +00:00
Boris Zbarsky
f31fe5e910 Bug 1619112 part 3. Pass UTF8 strings to MaybeRejectWithType/RangeError promise methods. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D65539

--HG--
extra : moz-landing-system : lando
2020-03-06 21:05:48 +00:00
Jan Varga
c603f2f85e Bug 1607692 - Wait for all normal origin operations to finish before shutting down QuotaManager; r=dom-workers-and-storage-reviewers,ttung
Differential Revision: https://phabricator.services.mozilla.com/D64989

--HG--
extra : moz-landing-system : lando
2020-03-03 08:47:07 +00:00
Jan Varga
1354a74058 Bug 1607692 - Change return type of QuotaUsageRequestBase::Init and QuotaRequestBase::Init from bool to void; r=dom-workers-and-storage-reviewers,ttung
These methods never return false, so they can be safely converted to return void.

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

--HG--
extra : moz-landing-system : lando
2020-03-03 08:12:41 +00:00
Jan Varga
45769a3be8 Bug 1606635 - Modify QuotaManager::OpenDirectory to return a pending lock; r=asuth,dom-workers-and-storage-reviewers,sg
Differential Revision: https://phabricator.services.mozilla.com/D64715

--HG--
extra : moz-landing-system : lando
2020-02-29 04:42:50 +00:00
Oana Pop Rus
d001aab6bf Backed out changeset ad8efac474bf (bug 1606635) for build bustages multiple failures in Context.cpp on a CLOSED TREE 2020-02-29 06:17:22 +02:00
Jan Varga
39371e357b Bug 1606635 - Modify QuotaManager::OpenDirectory to return a pending lock; r=asuth,dom-workers-and-storage-reviewers,sg
Differential Revision: https://phabricator.services.mozilla.com/D64715

--HG--
extra : moz-landing-system : lando
2020-02-29 04:02:13 +00:00
Jan Varga
e1fdbaccb4 Bug 1615552 - Enhance SimpleDB to support other persistence types; r=ttung,dom-workers-and-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D62058

--HG--
extra : moz-landing-system : lando
2020-02-27 13:46:43 +00:00
Tom Tung
b578ccf77b Bug 1618483 - Have a test to ensure the behavior between QMS::ClearClient and localStorage; r=dom-workers-and-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D64550

--HG--
extra : moz-landing-system : lando
2020-02-27 12:28:13 +00:00
Eric Rahm
e61be8e54e Bug 1617653 - Remove nsAutoPtr usage from localstorage, quota, storage, simpledb. r=dom-workers-and-storage-reviewers,sg
Differential Revision: https://phabricator.services.mozilla.com/D63913

--HG--
extra : moz-landing-system : lando
2020-02-25 23:14:57 +00:00
Sylvestre Ledru
ca6530131a Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan,kvark
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2020-02-24 15:33:38 +00:00
Jan Varga
34927b46f0 Bug 1616003 - QM: Make it possible to verify initialization status from unit tests; r=ttung,dom-workers-and-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D63052

--HG--
extra : moz-landing-system : lando
2020-02-22 07:57:28 +00:00
Jan Varga
0e36a593fa Bug 1615998 - QM: Remove nsIQuotaOriginsResult interface; r=ttung,dom-workers-and-storage-reviewers,sg
Differential Revision: https://phabricator.services.mozilla.com/D63051

--HG--
extra : moz-landing-system : lando
2020-02-22 01:03:26 +00:00
Simon Giesecke
9350e6b741 Bug 1613985 - Use MOZ_COUNTED_DEFAULT_CTOR_*/MOZ_COUNTED_DTOR_* macros. r=froydnj
This removes the need for explicit #ifdef NS_BUILD_REFCNT_LOGGING without
introducing user-defined destructors when it is not defined.

Also, some uses of virtual for declaring destructors are replaced by the
appropriate override declaration through these changes.

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

--HG--
extra : moz-landing-system : lando
2020-02-20 11:40:14 +00:00
Dorel Luca
d5f9df8ee1 Backed out 2 changesets (bug 1613985) for Build bustage on Windows2012. CLOSED TREE
Backed out changeset fd177b40b561 (bug 1613985)
Backed out changeset fb6d62b7f28d (bug 1613985)
2020-02-19 22:22:41 +02:00
Simon Giesecke
59b23375c0 Bug 1613985 - Use MOZ_COUNTED_DEFAULT_CTOR_*/MOZ_COUNTED_DTOR_* macros. r=froydnj
This removes the need for explicit #ifdef NS_BUILD_REFCNT_LOGGING without
introducing user-defined destructors when it is not defined.

Also, some uses of virtual for declaring destructors are replaced by the
appropriate override declaration through these changes.

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

--HG--
extra : moz-landing-system : lando
2020-02-19 18:05:38 +00:00
Jan Varga
29b9b41a82 Bug 1608759 - Forbid leaf common entries; r=ttung,dom-workers-and-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D62068

--HG--
extra : moz-landing-system : lando
2020-02-14 09:22:58 +00:00
Jan Varga
1ffac26af6 Bug 1608759 - Add "beforeInstall" key to package definitions; r=ttung,dom-workers-and-storage-reviewers
This is a preparation for "afterInitTemporaryStorage" key which requires initialized storage.

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

--HG--
extra : moz-landing-system : lando
2020-02-14 09:23:24 +00:00
Tom Tung
9bea5d80bc Bug 1610880 - Do not remove the empty origin directory when clearing a client; r=janv
Differential Revision: https://phabricator.services.mozilla.com/D62434

--HG--
extra : moz-landing-system : lando
2020-02-11 14:51:13 +00:00
Simon Giesecke
861998c782 Bug 1613985 - Use default for equivalent-to-default constructors/destructors in dom/quota. r=dom-workers-and-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D62557

--HG--
extra : moz-landing-system : lando
2020-02-12 10:25:22 +00:00
Tom Tung
9b0da9363f Bug 1609625 - P1 - Add a temporary scalar probes to get the longest initializattion time; r=janv,dom-workers-and-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D61231

--HG--
extra : moz-landing-system : lando
2020-02-10 10:43:06 +00:00
Jan Varga
4e80555e4f Bug 1608759 - Implement and use verifyStorage() function in all upgrade tests; r=dom-workers-and-storage-reviewers,ttung
The new verifyStorage() function takes current storage structure on disk and compares it with the expected structure. The expected structure is defined in JSON and consists of a per test package definition and a shared package definition. The shared package definition contains unknown files and directories which need to be ignored in all upgrade methods.
The new infrastructure for checking storage structure will be used later in other tests to verify handling of unknown or obsolete stuff for example during temporary storage initialization.

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

--HG--
extra : moz-landing-system : lando
2020-02-07 15:32:26 +00:00
Jan Varga
6f4faaf11f Bug 1608759 - installPackage() shouldn't allow file overwrites by default; r=dom-workers-and-storage-reviewers,ttung
Differential Revision: https://phabricator.services.mozilla.com/D61449

--HG--
extra : moz-landing-system : lando
2020-02-07 15:29:24 +00:00
Daniel Varga
1c197e92da Backed out 2 changesets (bug 1608759) for causing lint failure
CLOSED TREE

Backed out changeset cb706e608d58 (bug 1608759)
Backed out changeset f2a08319ac10 (bug 1608759)

--HG--
extra : amend_source : 251fcc6d6304fe6a4ed240f6d1d409fc168f1c31
2020-02-07 17:23:36 +02:00