Closed Bug 1916131 Opened 1 year ago Closed 1 year ago

Run `PRAGMA optimize` when closing an Skv database connection

Categories

(Core :: SQLite and Embedded Database Bindings, task)

task

Tracking

()

RESOLVED FIXED
133 Branch
Tracking Status
firefox133 --- fixed

People

(Reporter: lina, Assigned: lina)

References

(Blocks 1 open bug)

Details

Attachments

(2 files)

Marco suggested doing this in bug 1913241, comment 1, and we have a few examples of PRAGMA optimize(0x02) in the tree.

Pragmas, configuration options, and functions aren't schema-specific,
so having them in the skv::Schema type felt a bit confusing.

This commit:

  • Inlines and splits the logic from Schema::setup() into
    Connection::new() and skv::functions::register().
  • Renames ConnectionOpener to ConnectionMigrator, since the trait
    only handles migrations now.
Assignee: nobody → lina
Status: NEW → ASSIGNED
Attachment #9428982 - Attachment description: Bug 1916131 - Run `PRAGMA optimize` before closing an Skv connection. r?nanj! → Bug 1916131 - Run `PRAGMA optimize` for Skv connections. r?nanj!
Pushed by lbutler@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/a41cad75786c Refactor `ConnectionOpener` into `ConnectionMigrator`. r=nanj https://hg.mozilla.org/integration/autoland/rev/37a00e3f23e5 Run `PRAGMA optimize` for Skv connections. r=nanj
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 133 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: