Commit Graph

1254 Commits

Author SHA1 Message Date
Harveer Singh
be8935e470 Bug 1799717: Adding a try/catch block in the test to exempt some known possible failures.r=jari
Differential Revision: https://phabricator.services.mozilla.com/D210174
2024-05-13 21:07:26 +00:00
Harveer Singh
b984eaa428 Bug 1799717: Added some more diagnostics to diagnose test_caches_delete_after_shutdown.py.r=jari
Differential Revision: https://phabricator.services.mozilla.com/D209977
2024-05-10 17:46:50 +00:00
hsingh
59b1ebf0a9 Bug 1799717: Adding some diagnostics to debug intermittent marionette test.r=jstutte
Differential Revision: https://phabricator.services.mozilla.com/D198752
2024-04-30 14:04:25 +00:00
Jens Stutte
c3163ba9a5 Bug 1890291 - Do not shutdown StreamControl before all streams are closed. r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D204536
2024-04-26 12:37:54 +00:00
Nika Layzell
1e2dd10a71 Bug 1724083 - Part 2: Update Actor destruction checks for new manager list behaviour, r=ipc-reviewers,mccr8
After the changes in the previous part, actors are now removed from their
manager's managed list before invoking ActorDestroy. There were a few places in
tree which specifically checked for the old behaviour, due to calls from the
managed actor during ActorDestroy to potentially trigger clean-up.

This patch adjusts these checks to instead expect a count of `0` as the actor
will now already have been removed at that point.

Differential Revision: https://phabricator.services.mozilla.com/D198841
2024-04-22 17:31:06 +00:00
Mike Conley
a45d00e343 Bug 1891141 - Add configuration parameters for pages per step and step delay to mozIStorageAsyncConnection.backupToFileAsync. r=mak
This also fixes a bug in the test_connection_online_backup.js test which wasn't
properly evaluating that the page_size PRAGMA was being copied properly.

Differential Revision: https://phabricator.services.mozilla.com/D207471
2024-04-17 20:50:47 +00:00
Ryan VanderMeulen
e7a093d50c Bug 1883629 - Update Snappy to version 1.2.0. r=dom-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D203634
2024-04-08 13:48:06 +00:00
Emilio Cobos Álvarez
4fdaffa12c Bug 1889590 - Make cache DB use utf-8 for referrer strings. r=dom-storage-reviewers,janv,asuth
My understanding is that this should be safe to do. These have always
been utf-8 strings / urls anyways, and sqlite seems to handle returning
a TEXT field in both utf16 and utf8, and the DB should already use utf-8
encoding, so this change should just work, ideally?

But I'm not the most familiar with all that code so worth a
double-check.

Differential Revision: https://phabricator.services.mozilla.com/D206611
2024-04-05 07:16:33 +00:00
Emilio Cobos Álvarez
de09ab0dd6 Bug 1887719 - More consistently use UTF8String/nsCString for URLs. r=necko-reviewers,webidl,anti-tracking-reviewers,places-reviewers,jari,kershaw,janv,smaug,hsivonen
Sorry for the massive patch but I found it hard to split without
introducing a bunch of copies around...

This mostly makes necko and DOM agree on which strings to use, which
should result on less copies and conversions.

Differential Revision: https://phabricator.services.mozilla.com/D205601
2024-04-04 11:49:57 +00:00
Andrew Sutherland
4223b0b566 Bug 1887833 - Downgrade Cache API DB inconsistency assertion. r=dom-storage-reviewers,janv
We are downgrading this assertion since it's clearly happening and we
want a patch that is upliftable to beta; we will investigate and
address the potential logic problem separately.  (It could also just
be flipped memory bits; we need to investigate.)

Differential Revision: https://phabricator.services.mozilla.com/D206027
2024-03-28 16:38:09 +00:00
Jens Stutte
476c9374f3 Bug 1727526 - Abort DBAction::RunOnTarget if AppShutdown::IsInOrBeyond(ShutdownPhase::AppShutdownQM) r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D204587
2024-03-18 14:27:34 +00:00
Jens Stutte
07a7841983 Bug 1727526 - Add diagnostic assertions for StreamList to verify mList's book keeping. r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D204535
2024-03-18 14:27:34 +00:00
Marco Bonardo
5cac8986d2 Bug 1884308 - Chunk bookmark GUIDs when retrieving details to avoid going over Sqlite variables limit. r=mconley,places-reviewers,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D204660
2024-03-15 16:18:00 +00:00
Dave Townsend
8c6a552556 Bug 1864896: Autofix unused function arguments (dom). r=emilio,media-playback-reviewers,dom-storage-reviewers,padenot,janv
Differential Revision: https://phabricator.services.mozilla.com/D202962
2024-03-04 15:44:59 +00:00
Peter Van der Beken
a50f002c9b Bug 1640839 - Stop generating count of WebIDL enum values, use standard enum traits instead. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D201345
2024-03-02 07:50:25 +00:00
Peter Van der Beken
eebaaa23dc Bug 1640839 - Make WebIDL enum helper function to convert to string return an actual string. r=mccr8,media-playback-reviewers,padenot
Differential Revision: https://phabricator.services.mozilla.com/D201337
2024-03-02 07:50:21 +00:00
Natalia Csoregi
10b9ceb789 Backed out 13 changesets (bug 1640839) for causing bustage on Element.cpp CLOSED TREE
Backed out changeset 179ceb82c9e5 (bug 1640839)
Backed out changeset 73f498a821f0 (bug 1640839)
Backed out changeset dc2d3d0e0365 (bug 1640839)
Backed out changeset ddc989ac0509 (bug 1640839)
Backed out changeset e595bb3feea8 (bug 1640839)
Backed out changeset c85aca04e27f (bug 1640839)
Backed out changeset 98e8e3a4047a (bug 1640839)
Backed out changeset 59ef180517db (bug 1640839)
Backed out changeset af2f5e293662 (bug 1640839)
Backed out changeset 89aa6d9dc598 (bug 1640839)
Backed out changeset 67b722a722f9 (bug 1640839)
Backed out changeset 24a9665c6ced (bug 1640839)
Backed out changeset d93f199385e9 (bug 1640839)
2024-03-01 18:23:08 +02:00
Peter Van der Beken
22089d8166 Bug 1640839 - Stop generating count of WebIDL enum values, use standard enum traits instead. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D201345
2024-03-01 14:31:16 +00:00
Peter Van der Beken
171fc86507 Bug 1640839 - Make WebIDL enum helper function to convert to string return an actual string. r=mccr8,media-playback-reviewers,padenot
Differential Revision: https://phabricator.services.mozilla.com/D201337
2024-03-01 14:31:11 +00:00
hsingh
d3b62b3389 Bug 1858696: Created IDB and CacheAPI marionette tests to verify raw magic strings in on-disk storages.r=dom-storage-reviewers,webdriver-reviewers,whimboo,janv
Differential Revision: https://phabricator.services.mozilla.com/D192328
2024-02-02 15:14:24 +00:00
Gijs Kruitbosch
a1ea168c77 Bug 1780071 - autofix dom/ and layout/ violations of no-comparison-or-assignment-inside-ok r=media-playback-reviewers,dom-storage-reviewers,layout-reviewers,dom-core,emilio,mccr8,aosmond,tschuster,padenot,asuth
Differential Revision: https://phabricator.services.mozilla.com/D198976
2024-01-25 22:18:55 +00:00
Mike Conley
f27ff0993e Bug 1869060 - Add SQLite Online Backup API support via mozIStorageAsyncConnection. r=mak
Differential Revision: https://phabricator.services.mozilla.com/D195934
2024-01-22 14:26:53 +00:00
Henrik Skupin
144fe1476d Bug 1836727 - [marionette] Fix MARIONETTE_MANIFESTS usage in moz.build files. r=webdriver-reviewers,necko-reviewers,application-update-reviewers,search-reviewers,sessionstore-reviewers,places-reviewers,dom-storage-reviewers,Standard8,jesup,jdescottes,nalexander,sclements,janv
Differential Revision: https://phabricator.services.mozilla.com/D197515
2024-01-11 10:34:29 +00:00
Jan Varga
aeaf137c6b Bug 1871799 - Fix relevant quota clients to always use QuotaVFS for database access; r=dom-storage-reviewers,asuth
Some quota clients currently use the BaseVFS (instead of QuotaVFS) during
origin initialization which makes sense at first glance (there's no need to
track usage when temporary storage is only being initialized).
However, QuotaVFS provides other important functionality besides quota checks
which is the overridden xFullPathname method. The overridden implementation is
needed to avoid file path normalization on Windows.
This patch changes relevant quota clients to always use QuotaVFS, even during
origin initialization to take advantage of the overriden xFullPathname method.
There will be no quota checks during origin initialization just like before
because the passed directory lock id is -1. GetQuotaObject will return nullptr
in that case.

Depends on D198187

Differential Revision: https://phabricator.services.mozilla.com/D198188
2024-01-10 21:10:14 +00:00
hsingh
8cbf174733 Bug 1863990: Created new helpers in quota_test_case.py.r=janv,dom-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D195498
2024-01-09 15:42:26 +00:00
Tom Marble
4b00b49e47 Bug 1859908 - convert .ini manifests to .toml: batch 20 marionette.ini r=jmaher,webdriver-reviewers,necko-reviewers,application-update-reviewers,search-reviewers,sessionstore-reviewers,places-reviewers,dom-storage-reviewers,bytesized,kershaw,whimboo,dao,jesup,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D197206
2024-01-02 15:31:51 +00:00
hsingh
c294efd51a Bug 1871409: Moved back mInitRunnable clearing in Context::OnQuotaInit to its prior position.r=janv
Differential Revision: https://phabricator.services.mozilla.com/D197155
2023-12-22 16:18:13 +00:00
Jens Stutte
a696d9cd91 Bug 1870594 - Handle the no-CSCP case in StreamList::CloseAll. r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D196711
2023-12-21 06:53:25 +00:00
hsingh
33a724513a Bug 1869087: Properly handle QuotaInitRunnable failure in Context::OnQuotaInit.r=dom-storage-reviewers,janv
QuotaInitRunnable is invoked by Context to set up cache directory. This is not always successful as it could be
interrupted by shutdown or other filesystem issues. By the time in ran into error, it's possible that some objects
needed by Context are not yet initialized in QuotaInitRunnable::Run. Since QuotaInitRunnable internal state machine
will always transition to 'COMPLETING' and Context::OnQuotaInit would always be called; it's possible that some objects
like mDirectoryLock, mCipherKeyManager and mDirectoryMetadata didn't get initialized yet. As an effect, we should
only assert these objects being non-null in Context::OnQuotaInit if the QuotaInitRunnable was successful.

Differential Revision: https://phabricator.services.mozilla.com/D196113
2023-12-14 16:31:23 +00:00
Norisz Fay
a2413a9e0c Backed out changeset 04b0ed50a187 (bug 1869087) for causing multiple Quota related failures 2023-12-14 01:00:28 +02:00
hsingh
ec4cbf2fc7 Bug 1869087: Properly handle QuotaInitRunnable failure in Context::OnQuotaInit.r=dom-storage-reviewers,janv
QuotaInitRunnable is invoked by Context to set up cache directory. This is not always successful as it could be
interrupted by shutdown or other filesystem issues. By the time in ran into error, it's possible that some objects
needed by Context are not yet initialized in QuotaInitRunnable::Run. Since QuotaInitRunnable internal state machine
will always transition to 'COMPLETING' and Context::OnQuotaInit would always be called; it's possible that some objects
like mDirectoryLock, mCipherKeyManager and mDirectoryMetadata didn't get initialized yet. As an effect, we should
only assert these objects being non-null in Context::OnQuotaInit if the QuotaInitRunnable was successful.

Differential Revision: https://phabricator.services.mozilla.com/D196113
2023-12-13 18:24:33 +00:00
Joel Maher
4072dc32c4 Bug 1869590 - Batch 19 - convert remaining mochitest ini to toml. r=aryx,necko-reviewers,devtools-reviewers,dom-storage-reviewers,asuth,valentin,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D196203
2023-12-13 15:44:04 +00:00
Noemi Erli
c670ce0ba6 Backed out changeset f47f48be162a (bug 1869087) for causing crashes in StorageControllerTest CLOSED TREE 2023-12-13 05:46:07 +02:00
hsingh
08b837e173 Bug 1869087: Properly handle QuotaInitRunnable failure in Context::OnQuotaInit.r=dom-storage-reviewers,janv
QuotaInitRunnable is invoked by Context to set up cache directory. This is not always successful as it could be
interrupted by shutdown or other filesystem issues. By the time in ran into error, it's possible that some objects
needed by Context are not yet initialized in QuotaInitRunnable::Run. Since QuotaInitRunnable internal state machine
will always transition to 'COMPLETING' and Context::OnQuotaInit would always be called; it's possible that some objects
like mDirectoryLock, mCipherKeyManager and mDirectoryMetadata didn't get initialized yet. As an effect, we should
only assert these objects being non-null in Context::OnQuotaInit if the QuotaInitRunnable was successful.

Differential Revision: https://phabricator.services.mozilla.com/D196113
2023-12-13 00:57:19 +00:00
Jens Stutte
09e51b5d0e Bug 1727526 - Add more details to Context::Stringify. r=dom-storage-reviewers,janv
Depends on D191082

Differential Revision: https://phabricator.services.mozilla.com/D191084
2023-12-11 15:17:12 +00:00
Jens Stutte
349c746a19 Bug 1727526 - Have a Stringifyable base class. r=dom-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D191082
2023-12-11 15:17:12 +00:00
Jan Varga
c3f18dd105 Bug 1808294 - Rename EnsureTemporaryStorageIsInitialized to EnsureTemporaryStorageIsInitializedInternal; r=dom-storage-reviewers,asuth
One of the goals of the asynchronous temporary storage initialization is to
call EnsureTemporaryStorageIsInitialized only from InitTemporaryStorageOp.
Calling from other places including quota clients will be disallowed by
changing the method to a private method. The private nature of the method
should be emphasized by adding the Internal suffix.

Differential Revision: https://phabricator.services.mozilla.com/D188332
2023-12-08 05:55:04 +00:00
Jan Varga
e656633e14 Bug 1864264 - Create a base class for quota manager and quota client marionette tests; r=dom-storage-reviewers,webdriver-reviewers,whimboo,hsingh,asuth
Differential Revision: https://phabricator.services.mozilla.com/D193354
2023-12-05 01:34:04 +00:00
hsingh
31a97f729e Bug 1864684: Adjusting some tests for PBM.r=dom-storage-reviewers,anti-tracking-reviewers,janv,pbz
Tests browser_partitionedDOMCache.js and browser_cache_pb_window.js needed
to be adjusted for PBM.

Differential Revision: https://phabricator.services.mozilla.com/D195232
2023-12-04 21:48:49 +00:00
Jan Varga
bf2a048815 Bug 1866240 - Maintain usage information in the database; r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D195081
2023-12-01 22:38:10 +00:00
Cristian Tuns
07ea4344cd Backed out changeset 0279020821f5 (bug 1866240) for causing mochitest failures in test_cache_padding.html CLOSED TREE 2023-12-01 13:06:52 -05:00
Jan Varga
5be0701145 Bug 1866240 - Maintain usage information in the database; r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D195081
2023-12-01 16:57:13 +00:00
Joel Maher
9fc7cbc7bf Bug 1859890 - batch 14 convert xpcshell.ini -> .toml. r=aryx,dom-storage-reviewers,jesup
Differential Revision: https://phabricator.services.mozilla.com/D194162
2023-11-28 01:02:01 +00:00
Marco Bonardo
21a8c4d7e6 Bug 1855455 - Implement a loadExtension() API in mozStorage. r=asuth
The API can only load from a predetermined list of extensions statically built
in the same library as SQLite (either nss3 or mozsqlite3 at this time).
New extensions must be audited and their code updated through the update.sh
script.
All the extensions should be compilable and usable across all the tier1
platforms and from Rusqlite.

Differential Revision: https://phabricator.services.mozilla.com/D191316
2023-11-21 08:34:35 +00:00
Jan Rio Krause
e8b60da153 Bug 1734538 - Use NS_NewURI instead of MozURL. r=dom-storage-reviewers,jesup,asuth,janv
Differential Revision: https://phabricator.services.mozilla.com/D181805
2023-11-15 18:59:23 +00:00
Sandor Molnar
33f0b3f19a Backed out 3 changesets (bug 1855455) for causing build bustages at third_party/sqlite3/src/version
Backed out changeset 0a5cdc279edd (bug 1855455)
Backed out changeset f43c32558446 (bug 1855455)
Backed out changeset bda7a6ca45db (bug 1855455)
2023-11-15 19:17:16 +02:00
Marco Bonardo
982a9ab750 Bug 1855455 - Implement a loadExtension() API in mozStorage. r=asuth
The API can only load from a predetermined list of extensions statically built
in the same library as SQLite (either nss3 or mozsqlite3 at this time).
New extensions must be audited and their code updated through the update.sh
script.
All the extensions should be compilable and usable across all the tier1
platforms and from Rusqlite.

Differential Revision: https://phabricator.services.mozilla.com/D191316
2023-11-15 10:52:50 +00:00
Eden Chuang
5ca02c8ea0 Bug 1836700 - Remove BusyCount of WorkerPrivate. r=asuth,ipc-reviewers,mccr8
Differential Revision: https://phabricator.services.mozilla.com/D182718
2023-11-13 04:00:40 +00:00
Mark Banner
550bd1defe Bug 1863204 - Correct ESLint scope for some privileged globals and remove importGlobalProperties from more places. r=Gijs,sessionstore-reviewers,dom-storage-reviewers,sclements,asuth
Differential Revision: https://phabricator.services.mozilla.com/D192806
2023-11-10 08:29:10 +00:00
hsingh
6f566c88cf Bug 1856953: Created a marionette test to verify CacheAPI encryption.r=dom-storage-reviewers,webdriver-reviewers,janv,whimboo
Depends on D180298

Differential Revision: https://phabricator.services.mozilla.com/D190721
2023-10-27 14:10:09 +00:00