You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by Alex Karasulu <ak...@apache.org> on 2008/06/19 03:42:18 UTC

[ApacheDS] [Interceptors] Added new entry property to OperationContext

Hi Emmanuel,

I just added a new entry property to the OperationContext implementation in
the BB.  So now we can cache the target entry of any operation instead of
performing lookups all the time in various interceptors.  The property
allows getting and setting a ClonedServerEntry.  This is useful because we
can perform alterations on this entry and use getOriginalEntry() to get the
original state of the entry before any modifications are made to that entry.

The only tedious part to this is that we have to populate it at some point
(some barrier or interceptor) or else all the code accessing this entry will
need to check if it's null then do the lookup and call the setter.  Rather
than do this I was thinking we can eagerly load this in an interceptor or
have it eagerly loaded right as the OperationContext enters the
InterceptorChain via the chain itself.  Perhaps there are other options like
doing it in the constructors.

Wondering what your thoughts are on the best place for this if we should at
all leverage eager loading of this target entry.

Thanks,
Alex