Move most of checksetup's schema updates into Bugzilla::Install::DB

RESOLVED FIXED in Bugzilla 3.0



Installation & Upgrading
12 years ago
12 years ago


(Reporter: Max Kanat-Alexander, Assigned: Max Kanat-Alexander)


Bugzilla 3.0
Dependency tree / graph
Bug Flags:
approval +



(1 attachment, 1 obsolete attachment)



12 years ago
Okay, this is the big one. The whole --TABLE-- section of schema updates is going to be moved into Bugzilla::Install::DB.

I'm going to create one function: update_table_definitions. This is going to call a bunch of other private functions, so that it will be easy to read.

I may do this in pieces, we'll see.

Comment 1

12 years ago
Okay, it turns out that this patch depends on bug 289357, which requires review.

So, in order to avoid some terrible bitrot, I'm only going to move *most* changes into the module, in this patch. I'll leave a lot of the most recent changes in checksetup for now, and that way if there are any checkins before I check in this patch, it won't bitrot horribly.
Depends on: 289357
Summary: Move checksetup's schema updates into Bugzilla::Install::DB → Move most of checksetup's schema updates into Bugzilla::Install::DB

Comment 2

12 years ago
Created attachment 231584 [details] [diff] [review]

Okay, here's the patch. Here's what I've done:

1) Created Bugzilla::Install::DB.
2) Created a useful indicate_progress subroutine in there that people should use
   all the time if they're going to do something that takes a long time.
3) Split up all of the stuff that checksetup does with the tables into 
   individual subroutines that are all called by one main subroutine.
4) Fixed up some of the code that migrates groups from 2.16 so that it inserts
   users into the admin group directly, instead of waiting for checksetup
   to insert them into the admin group later.
Assignee: installation → mkanat

Comment 3

12 years ago
Requesting approval directly, as module owner, even though the patch isn't ready to check in yet (because it depends on bug 289357 being reviewed and checked in first).
Flags: approval?
Flags: approval? → approval+

Comment 4

12 years ago
Because of a checkin fix on bug 289357, I had to manually modify the patch before checking it in. I'll attach the fixed patch.

Checking in;
/cvsroot/mozilla/webtools/bugzilla/,v  <--
new revision: 1.533; previous revision: 1.532
RCS file: /cvsroot/mozilla/webtools/bugzilla/Bugzilla/Install/,v
Checking in Bugzilla/Install/;
/cvsroot/mozilla/webtools/bugzilla/Bugzilla/Install/,v  <--
initial revision: 1.1
Checking in Bugzilla/Install/;
/cvsroot/mozilla/webtools/bugzilla/Bugzilla/Install/,v  <--
new revision: 1.5; previous revision: 1.4
Last Resolved: 12 years ago
Resolution: --- → FIXED

Comment 5

12 years ago
Created attachment 231838 [details] [diff] [review]
Checked-In Version
Attachment #231584 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.