I have created a referral entry below the example partition like this:
dn: cn=theReferral,dc=example,dc=com
objectclass: top
objectClass: referral
objectClass: extensibleObject
cn: theReferral
ref:
ldap://someHost:389/cn=somewhere
Afterwards I have performed some searches in order to check whether ApacheDS returns a search result continuation reference. I used JNDI and set Context.REFERRAL to "throw" in order to check whether I get a ReferralException.
Case 1:
Base: dc=example,dc=com
Filter: (objectClass=*)
Scope: sub
=> ApacheDS delivers a continuation reference with the search result. I get an exception at the client.
Case 2:
Base: dc=example,dc=com
Filter: (cn=Nick Cave)
Scope: sub
=> Other than expected, ApacheDS does not deliver a continuation reference with the search result. No exception occurs.
Note that the only change is the filter expression.
I have created a JUnit testcase to demonstrate the situation. It has been successfully tested with other Directory servers (OpenLDAP, IBM, Sun). I'll attach it soon.