Skip to Content.
Sympa Menu

grouper-dev - RE: [grouper-dev] Action Items: Grouper-Dev Call 9-Jul-2008

Subject: Grouper Developers Forum

List archive

RE: [grouper-dev] Action Items: Grouper-Dev Call 9-Jul-2008

Chronological Thread 
  • From: Chris Hyzer <>
  • To: Emily Eisbruch <>, "" <>
  • Subject: RE: [grouper-dev] Action Items: Grouper-Dev Call 9-Jul-2008
  • Date: Wed, 9 Jul 2008 21:02:51 -0400
  • Accept-language: en-US
  • Acceptlanguage: en-US

> [AI] {Chris} will write an explanation of how hooks will be declared.

I added 3 Grouper lifecycle hooks, for grouper init, hooks init, and
hibernate init.

So now there are 3 ways to configure hooks, by declaring piecemeal in, by declaring one lifecycle hook which registers a suite
of hooks in java in the hooks init method, or I picture built in grouper
hooks / suites being declared in java and configured (turned on and off
perhaps) in the (when someone wants to do this the first
time I can do an example, just let me know the lifecycle hooks class and setting). This built in way would not require classes of
hooks or lifecycles configured in the (we will leave that
for user hooks or 3rd party hooks).

I documented these on the hooks page:


#### from documentation ####

To configure a hook, subclass one of the hooks base classes, e.g. GroupHooks,
MembershipHooks, etc. Then either register this in the
(see for documentation)

#implement a group hook by extending

Note you can register multiple hooks by comma separating them. Or you can
register runtime with:


If you want to register a suite of hooks, just register a lifecycle hook:


Then in the hook init method, register some hooks for the suite:

package edu.internet2.middleware.grouper.hooks;

import edu.internet2.middleware.grouper.hooks.beans.HooksContext;
import edu.internet2.middleware.grouper.hooks.logic.GrouperHooksUtils;

public class LifecycleHooksImpl extends LifecycleHooks {

* @see
public void hooksInit(HooksContext hooksContext,
HooksLifecycleHooksInitBean hooLifecycleHooksInitBean) {
GrouperHooksUtils.addHookManual("", MyGroupHooks.class);
GrouperHooksUtils.addHookManual("hooks.stem.class", MyStemHooks.class);


Finally, I picutre built-in grouper suites to just insert the registration
based on grouper config property in GrouperHooksUtils in the initHooks block.
To enable the suite the grouper properties file would just have a boolean
switch. When someone wants to get this working, let me know the grouper
properties config property and the LifecycleHooks subclass and I can do an

Archive powered by MHonArc 2.6.16.

Top of Page