Skip to Content.
Sympa Menu

grouper-dev - Re: [grouper-dev] improving db.init

Subject: Grouper Developers Forum

List archive

Re: [grouper-dev] improving db.init


Chronological Thread 
  • From: Tom Barton <>
  • To: Grouper Dev <>
  • Subject: Re: [grouper-dev] improving db.init
  • Date: Tue, 02 Sep 2008 14:36:26 -0500

Thanks Chris. I wonder if some sites would prefer a fatal error report rather than an auto-init upon detecting a corrupted database at startup. They might need the corrupted DB to aid in restoring normal operation.

Tom

Chris Hyzer wrote:
This is done:


https://bugs.internet2.edu/jira/browse/GRP-159


We briefly discussed this one, but trying to make it easier to get going with grouper...

Three db change tasks are confusing: schemaexport (ddl [and optionally init data]), db.init (ddl then insert default data), db.reset (remove all data, then init).

Now, when grouper starts, it checks to see if the root stem is missing, or if a builtin field is missing, or a builtin type type is missing, and if so, will init the DB. The only time this isnt sufficient is if some fields or types are there but not others (if someone manually deleted some), in which case the user can set the setting in the grouper.properties: ddlutils.schemaexport.installGrouperData to true, and do a schemaexport. I removed the ant tasks for db.init, db-init, and db.init.test, since they are no longer needed...

If there is a place where grouper is starting without initting, just add this to the code before initted data is needed:

GrouperStartup.startup();

Let me know if anyone has comments, I can always undo or change...

[ Show ยป <https://bugs.internet2.edu/jira/browse/GRP-159> ]

Chris Hyzer <https://bugs.internet2.edu/jira/secure/ViewProfile.jspa?name=mchyzer> - [24/Aug/08 09:24 PM - edited ] fixed Now, when grouper starts, it checks to see if the root stem is missing, or if a builtin field is missing, or a builtin type type is missing, and if so, will init the DB. The only time this isnt sufficient is if some fields or types are there but not others (if someone manually deleted some), in which case the user can set the setting in the grouper.properties: ddlutils.schemaexport.installGrouperData to true, and do a schemaexport. I removed the ant tasks for db.init, db-init, and db.init.test, since they are no longer needed... If there is a place where grouper is starting without initting, just add this to the code before initted data is needed: GrouperStartup.startup(); Let me know if anyone has comments, I can always undo or change...


Chris


begin:vcard
fn:Tom Barton
n:Barton;Tom
org:University of Chicago;Networking Services & Information Technologies
email;internet:
title:Sr. Director for Integration
tel;work:+1 773 834 1700
version:2.1
end:vcard




Archive powered by MHonArc 2.6.16.

Top of Page