grouper-dev - RE: [grouper-dev] MembershipHooks high vs not high level hooks
Subject: Grouper Developers Forum
List archive
- From: Chris Hyzer <>
- To: Colin Hudler <>
- Cc: "" <>
- Subject: RE: [grouper-dev] MembershipHooks high vs not high level hooks
- Date: Thu, 25 Jun 2009 16:00:47 -0400
- Accept-language: en-US
- Acceptlanguage: en-US
Im not sure I understand why you would use this hook and not
membershipPostCommitInsert and membershipPostCommitDelete?
Also, if notifications / change log existed in 2.4, you would use that right?
Thanks!
Chris
> This hook notifies a udp listener of membership changes. The listener
> then takes action, in this case, updating an LDAP database.
>
> I registered two hooks.
>
> membershipPostCommitRemoveMember
> membershipPostCommitAddMember
>
> I could not easily predict when the hooks would fire, so it is their
> job
> to filter the event before notifying. Please forgive this crude code
> fragment, but I think it illustrates what I am doing:
>
> Set memberships = postCommitBeanThread.getMembershipEffectiveSaves();
> memberships.addAll(postCommitBeanThread.getMembershipImmediateSaves());
> Iterator memberator = memberships.iterator();
> while (memberator.hasNext()) {
> Membership membership = (Membership) memberator.next();
> String listName = membership.getListName();
> if (!listName.equals("members")) { memberator.next(); continue; }
> // Proceed to process this event...
>
>
> This works well so far.
- MembershipHooks high vs not high level hooks, Colin Hudler, 06/24/2009
- RE: [grouper-dev] MembershipHooks high vs not high level hooks, Chris Hyzer, 06/24/2009
- Re: [grouper-dev] MembershipHooks high vs not high level hooks, Colin Hudler, 06/24/2009
- RE: [grouper-dev] MembershipHooks high vs not high level hooks, Chris Hyzer, 06/24/2009
- Re: [grouper-dev] MembershipHooks high vs not high level hooks, Colin Hudler, 06/25/2009
- RE: [grouper-dev] MembershipHooks high vs not high level hooks, Chris Hyzer, 06/25/2009
- Re: [grouper-dev] MembershipHooks high vs not high level hooks, Colin Hudler, 06/25/2009
- RE: [grouper-dev] MembershipHooks high vs not high level hooks, Chris Hyzer, 06/25/2009
- Re: [grouper-dev] MembershipHooks high vs not high level hooks, Colin Hudler, 06/25/2009
- RE: [grouper-dev] MembershipHooks high vs not high level hooks, Chris Hyzer, 06/24/2009
- Re: [grouper-dev] MembershipHooks high vs not high level hooks, Colin Hudler, 06/24/2009
- RE: [grouper-dev] MembershipHooks high vs not high level hooks, Chris Hyzer, 06/24/2009
Archive powered by MHonArc 2.6.16.