This is what I really disliked about LdapName and Attributes.  There had to be both an immutable version and a mutable version of them.  For now we could use clone() heavily so any changes on the returned result set or added entry won't affect the stored entries at all.

On 6/6/06, Ersin Er <ersin.er@gmail.com> wrote:
Hi all,

I'm currently working LDAP Triggers as a somewhat cool addition to
ApacheDS. The progress can be partially followed from:

http://docs.safehaus.org/display/APACHEDS/Triggers

We allow interception of each LDAP operation with BEFORE, AFTER and
INSTEADOF triggers. There are lots of details to share but currently I
have an important question where I need some suggestions. (I'll be
sharing much more in a month.)

We allow operation specific parameters to be injected to Stored
Procedures fired by Triggers. The question is: Shall we allow
modification of these parameters by stored procedures? Shall we pass
references of real (meaning the object itself which takes place in the
operation) mutable objects and allow modification of those values? For
example, if someone performs a add operation, shall we allow the
Trigger/SP writer to modify the attributes of the entry to be added? Or
from the other perspective, shall we allow modification of search
results for instance?

Another problem is, if we allow this modification, what shall we do with
immutable types? For example, a compare operation results a boolean (I
mean the Java type) and it cannot be altered within a method it's passed.

BTW, we'll have some working Triggers/SPs in one month as we plan and
wish. Then we may further investigate what's missing and what can be
improved all together.

Thanks.

--
Ersin



--
what we call human nature is actually human habit
--
http://gleamynode.net/
--
PGP key fingerprints:
* E167 E6AF E73A CBCE EE41  4A29 544D DE48 FE95 4E7E
* B693 628E 6047 4F8F CFA4  455E 1C62 A7DC 0255 ECA6