directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kiran Ayyagari <kayyag...@apache.org>
Subject Re: Change Sequence Number
Date Fri, 24 May 2013 20:06:55 GMT
On Fri, May 24, 2013 at 8:38 PM, Emmanuel Lécharny <elecharny@gmail.com>wrote:

> Le 5/24/13 4:33 PM, Rina Kotadia a écrit :
> > Hi ,
> > We are synchronizing users/groups from ApacheDS to our database using
> JNDI.
> > Have following questions
> >
> > Que 1) I wanted to know to take users and group created/updated after
> last
> > synchronization which attribute I can use for changes happen on server?
>
> Every modified entry has an OperationalAttribute containing the date of
> the last modification. You can fetch all the modified entry with such a
> filter :
>
> (modifyTimeStamp>={last modification synchro})
>
> For instance :
>
> (modifyTimeStamp>=20130524145400.000Z) (gives back all the entry
> modified since may, 24, 2013, 14:54)
>
> Of course, if you added some entries, they won't have this
> modifyTimeStamp attribute. You can improve the former filter by
> convering this use case :
>
> (|(!(modifyTimestamp=*))(modifyTimeStamp>=20130524145400.000Z))
>
> >
> > Que 2) I found one "Change Sequence Number".If I want to take last
> > committed "CSN" how I can get this?
>
> This CSN is an internal attribute which is used for replication. You
> can't really get back the last one in LDAP.
>
> a small correction here, when replication is enabled(which is enabled by
default) the last created CSN is
stored in each partition's root under 'contextCSN' attribute
so you can use a filter like
(entryCSN>={value-of-the-contextCSN})
to get the last modified entries

Note: using JNDI without the syncrepl control the order of events is not
guaranteed

> >
> > Que 3) If I have nested groups and add one user in subgroup,how can I
> track
> > this change in parent group ?
> What is your data structure here ? Are the subgroups stored using the
> 'member' Attribute in the parent group ? If so, you won't be able to
> know that the parent group ha sbeen modified because one of its subgroup
> has been modified.
>
>
> --
> Regards,
> Cordialement,
> Emmanuel Lécharny
> www.iktek.com
>
>


-- 
Kiran Ayyagari
http://keydap.com

Mime
View raw message