[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Fwd: syncrepl inseard of back-perl ?



On Sunday, 27 September 2009 16:39:32 Brett @Google wrote:
> Hello,
>
> I was wondering if there are any concrete examples of using syncrepl
> to monitor a slapd for changes, and perform some scripted operation if
> the monitored data changes. I can think of several cases where this
> might be very handy, where you want to run a script or custom business
> logic, on receipt of some data being changed.
>
> I have seen some examples in the 2.3.x days, where slurpd was used to
> push changes to a back-perl script, which then did some custom
> business logic and it did fill an very useful niche. I imagine these
> post-slurp syncrepl days you could use the syncrepl protocol in a push
> mode via a proxy to push changes at a back-perl instance to the same
> sort of thing.
>
> But perhaps using syncrepl directly might seem like a better option,
> as this has been touted as a benefit of syncrepl, although i have not
> seen any specific examples.. To this end, i am wondering are the
> syncrepl client parts of slapd usable outside the context of the slapd
> binary? Has anyone tried this and has any examle code they are willing
> to share ?

I used Net::LDAPapi's syncrepl support to do this. A few hundred line script 
is the integration between a qmail-ldap installation and a zimbra installation 
(most of the script is actually handling differences between the two systems; 
formats, e.g. catchalls, out of office settings etc.) until the provisioning 
system catches up to provision directly ...

If you need an example I may be able to send it to you off-list.

Regards,
Buchan