Closed Bug 325287 Opened 19 years ago Closed 16 years ago

storage file reorg

Categories

(Toolkit :: Storage, defect)

defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: bryner, Unassigned)

References

Details

Attachments

(1 file, 1 obsolete file)

1. We need to get away from using .sdb as a file extension, see http://www.sqlite.org/cvstrac/wiki?p=PerformanceTuningWindows section 5.

2. We should provide an easy way to name storage files in the profile directory without requiring all callers to use the directory service or hardcode the file extension.

This change impacts Calendar, so cc'ing those people.  dmose thought calendar could just hook in some migration to rename storage.sdb if it exists.
Attached patch patch (obsolete) — Splinter Review
Like so.  Note that this also changes the base name of the default file to "profile", as brettw suggested (to make it look less like something that can be deleted to free up space).
Attachment #210203 - Flags: first-review?(vladimir)
Comment on attachment 210203 [details] [diff] [review]
patch

Looks fine to me.
Attachment #210203 - Flags: first-review?(vladimir) → first-review+
That doc recommends .db or .dat instead of .sdb.  Any reason not to go with one of those?
(In reply to comment #3)
> That doc recommends .db or .dat instead of .sdb.  Any reason not to go with one
> of those?

Too generic, IMO (note that that doc is just a wiki page written up by someone, not an official doc).  We don't have any supported systems with 8.3 limitations any more, and .sqlite gives people a hint to what file format is in use if they poke around their profile directory.  .db is already used for the cert db (berkeley db).
Blocks: 325171
just to update, this is on hold until we figure out proper migration for apps such as sunbird.
I'm marking this as blocking Lightning 0.1, as I think that having fewer users hit the migration code avoids trouble.  I'd like to propose that the migration code live in storage, as otherwise it is hard to guarantee that any migration has done before someone opens the database for the very first time (since it seems plausible that future Thunderbird versions will open the database before any extensions are loaded).
bryner: I'd like this make Lightning 0.1, which means it needs to land in the next couple of days.  I propose taking over this bug, adding code to storage which will automatically rename any existing database (as per comment 6), and driving both that patch and the one that you've already submitted into the tree.  Are you ok with this?
bryner OK'ed my proposal in comment 7; I'll go ahead with it soon.
Assignee: bryner → dmose
Whiteboard: [ETA 2/24]
Whiteboard: [ETA 2/24]
Is it OK to actually use .sqlite?  Will that work on win95 (and other crappy OSes) with non-vfat drives?
This is an un-bitrotted version of bryner's patch, and a work in progress.  A bunch of the error-handling code still needs to be written.  It doesn't include a patch to satchel like first version, as there is already a patch in the tree that opens a specific, separate database for formhistory.
Attachment #210203 - Attachment is obsolete: true
No longer blocks: lightning-0.1
Assigning bugs that I'm not actively working on back to nobody; use
SearchForThis as a search term if you want to delete all related bugmail at
once.
Assignee: dmose → nobody
This isn't a valid storage bug
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: