Skip to Content.
Sympa Menu

grouper-dev - improving db.init

Subject: Grouper Developers Forum

List archive

improving db.init


Chronological Thread 
  • From: Chris Hyzer <>
  • To: Grouper Dev <>
  • Subject: improving db.init
  • Date: Sun, 24 Aug 2008 21:44:57 -0400
  • Accept-language: en-US
  • Acceptlanguage: en-US

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 » ]

Chris Hyzer - [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



  • improving db.init, Chris Hyzer, 08/24/2008

Archive powered by MHonArc 2.6.16.

Top of Page