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
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
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
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
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
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
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
Set a default journal_size_limit, so journals are always truncated to a sensible
max size. Change existing consumers to just use the default, but Places that is
using a larger 4MiB limit.
Change auxiliary files (-shm, -journal, -wal, ...) persistance on disk, to
avoid the cost of creating and removing them. Since there is a journal_size_limit
they will be truncated instead of deleted.
Differential Revision: https://phabricator.services.mozilla.com/D172185
As previously discussed, we're not using this telemetry at the moment, we used
it in the past to study main thread IO.
Simplifying the VFS allows us to more easily experiment with other settings
in the future.
Differential Revision: https://phabricator.services.mozilla.com/D172016
Add asyncVacuum to mozIStorageAsyncConnection, that dispatches a runnable to
the helper thread, where it will execute a full or incremental vacuum, depending
on the connection auto_vacuum value.
It also supports vacuuming attached schemas.
asyncVacuum() supports changing both the page_size and auto_vacuum.
Change mozIStorageVacuumParticipant to return a mozIStorageAsyncConnection and
allow specifying whether incremental vacuum should be enabled.
Change vacuumManager notification from heavy-io-task to vacuum-begin and vacuum-end
since the original proposal of notifying heavy IO didn't take off.
Cleanup test_vacuum to be able to use instances of the test VacuumParticipant,
that means we can remove the no more necessary registerESM hack.
Fix Places History as the only cpp consumer.
Differential Revision: https://phabricator.services.mozilla.com/D168298
Add asyncVacuum to mozIStorageAsyncConnection, that dispatches a runnable to
the helper thread, where it will execute a full or incremental vacuum, depending
on the connection auto_vacuum value.
It also supports vacuuming attached schemas.
asyncVacuum() supports changing both the page_size and auto_vacuum.
Change mozIStorageVacuumParticipant to return a mozIStorageAsyncConnection and
allow specifying whether incremental vacuum should be enabled.
Change vacuumManager notification from heavy-io-task to vacuum-begin and vacuum-end
since the original proposal of notifying heavy IO didn't take off.
Cleanup test_vacuum to be able to use instances of the test VacuumParticipant,
that means we can remove the no more necessary registerESM hack.
Fix Places History as the only cpp consumer.
Differential Revision: https://phabricator.services.mozilla.com/D168298