Commit Graph

1427 Commits

Author SHA1 Message Date
Florian Quèze
f910267fcf Bug 1842682 - Remove unused ChromeUtils.requestIOActivity and IOActivityMonitor, r=necko-reviewers,valentin.
Differential Revision: https://phabricator.services.mozilla.com/D210680
2024-05-17 14:03:21 +00:00
Emilio Cobos Álvarez
8aaf44fea9 Bug 1893683 - Remove ns{A,C}String and other xpcom dependencies from nsStringBuffer. r=smaug,media-playback-reviewers,karlt
* nsStringBuffer::FromString -> nsTSubString::GetStringBuffer
 * nsStringBuffer::ToString -> nsTSubString::Assign(nsStringBuffer*, len)
 * Move refcounting inline but refcount-logging and other XPCOM-related
   things out-of-line.

Differential Revision: https://phabricator.services.mozilla.com/D208771
2024-05-09 08:34:35 +00:00
Jari Jalkanen
5fc7e3f469 Bug 1894261 - Protect concurrent access to connection interrupt test variables. r=dom-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D209256
2024-05-07 18:49:27 +00:00
Jari Jalkanen
95545ed3ab Bug 1894261 - Enable SynchronousConnectionInterruptionTest for TSAN. r=RyanVM
Differential Revision: https://phabricator.services.mozilla.com/D209373
2024-05-07 18:49:27 +00:00
Ryan VanderMeulen
0e07c8c08e Bug 1806946 - Skip GTests which fail when run under TSAN. r=profiler-reviewers,dom-storage-reviewers,tnikkel,xpcom-reviewers,ipc-reviewers,mccr8,janv,webrtc-reviewers,pehrsons,canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D209175
2024-05-02 13:09:07 +00:00
Mike Conley
8b8218c610 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
Emilio Cobos Álvarez
e4ddf24147 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
abhishekmadan30
6118a3b4b6 Bug 1884941 - Add an option to URLParams::Parse() for if it should decode the parameters or not. r=anti-tracking-reviewers,necko-reviewers,valentin,timhuang.
Differential Revision: https://phabricator.services.mozilla.com/D204914
2024-03-28 18:02:16 +00:00
Iulian Moraru
93ed708a97 Backed out 3 changesets (bug 1877419, bug 1884941) for causing non unified build bustages on URLQueryStringStripper.cpp. CLOSED TREE
Backed out changeset 53db0be27620 (bug 1877419)
Backed out changeset b7fab4b145f7 (bug 1877419)
Backed out changeset 78436da20d95 (bug 1884941)
2024-03-26 19:37:45 +02:00
abhishekmadan30
6053848bf6 Bug 1884941 - Add an option to URLParams::Parse() for if it should decode the parameters or not. r=anti-tracking-reviewers,necko-reviewers,valentin,timhuang.
Differential Revision: https://phabricator.services.mozilla.com/D204914
2024-03-26 14:42:07 +00:00
Noemi Erli
18b56b463a Backed out 3 changesets (bug 1884941, bug 1877419) for causing bustage in URLQueryStringStripper.cpp CLOSED TREE
Backed out changeset 32c74a4cd05b (bug 1877419)
Backed out changeset c2ca2f596c09 (bug 1877419)
Backed out changeset 45931e6db21e (bug 1884941)
2024-03-25 21:50:27 +02:00
abhishekmadan30
c4a54c7864 Bug 1884941 - Add an option to URLParams::Parse() for if it should decode the parameters or not. r=anti-tracking-reviewers,necko-reviewers,valentin,timhuang.
Differential Revision: https://phabricator.services.mozilla.com/D204914
2024-03-25 18:30:38 +00:00
Marco Bonardo
5a15e88f6a 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
Gabriele Svelto
aa43fa218e Bug 1831092 - Use the new pull-based API for all crash annotations and remove the global annotations table r=jgilbert,necko-reviewers,media-playback-reviewers,profiler-reviewers,win-reviewers,padenot,handyman,afranchuk,valentin,alwu,sotaro
This changes comes with several different refactorings all rolled into one,
unfotunately I couldn't find a way to pull them apart:
- First of all annotations now can either recorded (that is, we copy the value
  and have the crash reporting code own the copy) or registered. Several
  annotations are changed to use this functionality so that we don't need to
  update them as their value change.
- The code in the exception handler is modified to read the annotations from
  the mozannotation_client crate. This has the unfortunate side-effect that
  we need three different bits of code to serialize them: one for annotations
  read from a child process, one for reading annotations from the main process
  outside of the exception handler and one for reading annotations from the
  main process within the exception handler. As we move to fully
  out-of-process crash reporting the last two methods will go away.
- The mozannotation_client crate now doesn't record annotation types anymore.
  I realized as I was working on this that storing types at runtime has two
  issues: the first one is that buggy code might change the type of an
  annotation (that is record it under two different types at two different
  moments), the second issue is that types might become corrupt during a
  crash, so better enforce them at annotation-writing time. The end result is
  that the mozannotation_* crates now only store byte buffers, track the
  format the data is stored in (null-terminated string, fixed size buffer,
  etc...) but not the type of data each annotation is supposed to contain.
- Which brings us to the next change: concrete types for annotations are now
  enforced when they're written out. If an annotation doesn't match the
  expected type it's skipped. Storing an annotation with the wrong type will
  also trigger an assertion in debug builds.

Differential Revision: https://phabricator.services.mozilla.com/D195248
2024-03-04 10:24:43 +00:00
Dave Townsend
bd175a2d84 Bug 1864896: Autofix unused function arguments (storage). r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D202988
2024-03-01 23:43:54 +00:00
Mike Conley
4259a99082 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
Mike Conley
f893e12aea Bug 1869060 - Move old backupDatabaseFile utility out from mozIStorageService to a Places helper. r=mak,places-reviewers
This utility copies an SQLite database, but does so just by performing a file
copy on the database itself. It assumes that there are no open connections on
the underlying database file.

Given that this is only used by Places, and that a later patch in this stack
adds a database backup utility that works even if there are open connections,
means we can move this old utility out form the mozIStorageService and into
a dedicated Places helper instead.

Differential Revision: https://phabricator.services.mozilla.com/D198309
2024-01-22 14:26:52 +00:00
Tomislav Jovanovic
11996c6f38 Bug 1871991 - Required arguments after optional are not supported r=jesup
I reviewed all js callsites, and they always use all arguments,
so this should  be no-op.

Differential Revision: https://phabricator.services.mozilla.com/D197300
2024-01-04 02:06:08 +00:00
Joel Maher
81afbdce9a Bug 1859896 - Batch 16 - convert xpcshell.ini -> .toml. r=aryx,webdriver-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D194383
2023-11-25 21:08:44 +00:00
Marco Bonardo
497899ec5d 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
Marco Bonardo
b3b546b288 Bug 1855455 - Vendor SQLite and FTS5 as a run-time loadable extension. r=asuth,glandium
Move SQLite updates to the `mach vendor` system to simplify updates.
This will have to be invoked manually through `./mach vendor`, as updatebot
is not hooked up yet (tracking new versions through Github tags is not reliable).

Build FTS5 statically in the same library as SQLite, but as a run-time
loadable extension.
Other extensions will similarly be added in the future, consumers can then use
mozStorage `loadExtension()` or Rusqlite `load_extension()` to load them.
FTS5 is used as a first example and for unit tests. While it could be enabled
statically, we prefer to have it on-demand and per connection.

Differential Revision: https://phabricator.services.mozilla.com/D191314
2023-11-21 08:34:34 +00:00
Butkovits Atila
5ac3149a96 Backed out changeset dafb434a3dd2 (bug 1855455) for causing build bustages. CLOSED TREE 2023-11-21 10:28:13 +02:00
Marco Bonardo
1ba9c659c7 Bug 1855455 - Vendor SQLite and FTS5 as a run-time loadable extension. r=asuth,glandium
Move SQLite updates to the `mach vendor` system to simplify updates.
This will have to be invoked manually through `./mach vendor`, as updatebot
is not hooked up yet (tracking new versions through Github tags is not reliable).

Build FTS5 statically in the same library as SQLite, but as a run-time
loadable extension.
Other extensions will similarly be added in the future, consumers can then use
mozStorage `loadExtension()` or Rusqlite `load_extension()` to load them.
FTS5 is used as a first example and for unit tests. While it could be enabled
statically, we prefer to have it on-demand and per connection.

Differential Revision: https://phabricator.services.mozilla.com/D191314
2023-11-21 08:08:44 +00:00
Patryk Gruszka
1239337577 Bug 1862507 - mozStorageSQLFunctions.cpp: do not use 'else' after 'return'. r=sylvestre DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D193493
2023-11-16 08:19:48 +00:00
Sandor Molnar
ec89f35c95 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
94ef632ae2 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
Marco Bonardo
7ddc1e299a Bug 1855455 - Vendor SQLite and FTS5 as a run-time loadable extension. r=asuth,glandium
Move SQLite updates to the `mach vendor` system to simplify updates.
This will have to be invoked manually through `./mach vendor`, as updatebot
is not hooked up yet (tracking new versions through Github tags is not reliable).

Build FTS5 statically in the same library as SQLite, but as a run-time
loadable extension.
Other extensions will similarly be added in the future, consumers can then use
mozStorage `loadExtension()` or Rusqlite `load_extension()` to load them.
FTS5 is used as a first example and for unit tests. While it could be enabled
statically, we prefer to have it on-demand and per connection.

Differential Revision: https://phabricator.services.mozilla.com/D191314
2023-11-15 10:52:49 +00:00
Sylvestre Ledru
1e776756dd Bug 1856795 - ride along: use = default; on some recently modified files r=emilio
More on:
https://clang.llvm.org/extra/clang-tidy/checks/modernize/use-equals-default.html

Command:
L=$(hg export -r tip|grep +++|cut -d/ -f2-)
./mach static-analysis check --checks="-*, modernize-use-equals-default" --fix $L

Differential Revision: https://phabricator.services.mozilla.com/D191016
2023-10-15 15:29:03 +00:00
Sylvestre Ledru
d0f6c7fc66 Bug 1856795 - Remove redundant member init r=emilio
Done with:
./mach static-analysis check --checks="-*, readability-redundant-member-init" --fix .

https://clang.llvm.org/extra/clang-tidy/checks/readability/redundant-member-init.html

Differential Revision: https://phabricator.services.mozilla.com/D190002
2023-10-15 15:29:02 +00:00
Cristina Horotan
6a90f5eded Backed out 2 changesets (bug 1856795) for causing build bustage at BasicEvents.h CLOSED TREE
Backed out changeset 1d98b028923a (bug 1856795)
Backed out changeset eae2ac93e17c (bug 1856795)
2023-10-14 21:42:14 +03:00
Sylvestre Ledru
c164bd9937 Bug 1856795 - ride along: use = default; on some recently modified files r=emilio
More on:
https://clang.llvm.org/extra/clang-tidy/checks/modernize/use-equals-default.html

Command:
L=$(hg export -r tip|grep +++|cut -d/ -f2-)
./mach static-analysis check --checks="-*, modernize-use-equals-default" --fix $L

Differential Revision: https://phabricator.services.mozilla.com/D191016
2023-10-14 17:34:27 +00:00
Sylvestre Ledru
cc8a0ee742 Bug 1856795 - Remove redundant member init r=emilio
Done with:
./mach static-analysis check --checks="-*, readability-redundant-member-init" --fix .

https://clang.llvm.org/extra/clang-tidy/checks/readability/redundant-member-init.html

Differential Revision: https://phabricator.services.mozilla.com/D190002
2023-10-14 17:34:26 +00:00
Marco Bonardo
30115fd206 Bug 1855448 - Cleanup: remove non necessary SQLITE_MAX_LIKE_PATTERN_LENGTH define. r=asuth
Depends on D189392

Differential Revision: https://phabricator.services.mozilla.com/D189393
2023-09-28 11:41:47 +00:00
Marco Bonardo
69b45023f2 Bug 1855448 - Enable Sqlite FTS3 extension only for Thunderbird and Seamonkey. r=asuth,mkmelin
Differential Revision: https://phabricator.services.mozilla.com/D189392
2023-09-28 11:41:47 +00:00
hsingh
b2cc4c68f4 Bug 1843229: Created header files to declare external functions in BaseVFS.cpp, QuotaVFS.cpp and ObfuscatingVFS.cpp.r=janv,dom-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D187992
2023-09-26 14:51:38 +00:00
hsingh
e941d3eb16 Bug 1843229: Fixing wrong cast.r=janv,dom-storage-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D187283
2023-09-26 14:51:38 +00:00
Marco Bonardo
ae32ce0ce1 Bug 1834043 - Add a configure option to disable Sqlite auxiliary files persistence. r=glandium,tjr
Not using a pref because Storage has connections using helper threads and the
main thread, thus we prefer to avoid mutex costs for a pref we'll likely not
use in Firefox. Also using a "once" pref would require some coordination because
Storage may try to lazy init once prefs from different threads concurrently,
causing potential deadlocks.

Differential Revision: https://phabricator.services.mozilla.com/D183724
2023-08-01 08:02:34 +00:00
Marco Bonardo
f104bcd4be Bug 1834043 - Enable Sqlite auxiliary files persistence in Release. r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D182770
2023-08-01 08:02:33 +00:00
Marco Bonardo
016cc78dda Bug 1638256 - Some casts and fixes in mozStorage to make clang-tidy happy. r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D181551
2023-06-24 10:11:28 +00:00
Marco Bonardo
95fe144ede Bug 1638256 - Use mTelemetryFilename for the mozStorage thread name. r=asuth
Depends on D181037

Differential Revision: https://phabricator.services.mozilla.com/D181038
2023-06-24 10:11:28 +00:00
Marco Bonardo
81f54fd826 Bug 1638256 - Initialize mTelemetryFilename in the Connection constructor. r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D181037
2023-06-24 10:11:28 +00:00
Norisz Fay
45e83e3152 Backed out 3 changesets (bug 1638256) for causing GTest failures CLOSED TREE
Backed out changeset 556614d4b90a (bug 1638256)
Backed out changeset dfd4d3679ccf (bug 1638256)
Backed out changeset 30c66c06f6ce (bug 1638256)
2023-06-21 22:41:40 +03:00
Marco Bonardo
02b6c343ec Bug 1638256 - Some casts and fixes in mozStorage to make clang-tidy happy. r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D181551
2023-06-21 18:47:19 +00:00
Marco Bonardo
48ecbc8fd9 Bug 1638256 - Use mTelemetryFilename for the mozStorage thread name. r=asuth
Depends on D181037

Differential Revision: https://phabricator.services.mozilla.com/D181038
2023-06-21 18:47:19 +00:00
Marco Bonardo
6bfee9629b Bug 1638256 - Initialize mTelemetryFilename in the Connection constructor. r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D181037
2023-06-21 18:47:19 +00:00
Mark Banner
130a655906 Bug 1826062 - Automatic fixes for upgrading Prettier to 2.8.8. r=mossop,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,denschub,devtools-reviewers,sparky,calu
Differential Revision: https://phabricator.services.mozilla.com/D177027
2023-05-20 12:26:53 +00:00
Mark Banner
8219a5c503 Bug 1826062 - Automatic fixes for Prettier 2.0.5 upgrade. r=mossop,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,denschub,devtools-reviewers,sparky,owlish
Differential Revision: https://phabricator.services.mozilla.com/D177025
2023-05-20 12:26:49 +00:00
Mike Hommey
17cb194f8d Bug 1833799 - Avoid a copy that clang 7 warns about. r=dom-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D178417
2023-05-18 21:31:33 +00:00
Jan Varga
e0a38c914c Bug 1833233 - Add description for some database header fields; r=dom-storage-reviewers,hsingh,asuth
Differential Revision: https://phabricator.services.mozilla.com/D178230
2023-05-16 20:59:36 +00:00
hsingh
cc5fae2ee8 Bug 1833233: Fix incremental vacuum on encrypted sqlite IDB databases.r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D178200
2023-05-16 19:44:36 +00:00