directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Simon.Tem...@saaconsultants.com
Subject NPE Defect in Latest Directory - 1.0.2
Date Fri, 01 Jun 2007 08:54:19 GMT
We've found a problem with DS 1.0.2.  This problem only exists when running with DS embedded
in the same VM.
Running the same code remotely (outside of DS VM) works fine.

Example code:

   ....
            Attributes attrs = new BasicAttributes();
            attrs.put("objectClass", "organizationalUnit");
            attrs.put("description", "Test OU");
            
            DirContext subContext = context.createSubcontext("ou=Test", attrs);


Exception from createSubcontext():

Caused by: java.lang.NullPointerException
 at org.apache.directory.shared.ldap.util.AttributeUtils.containsValueCaseIgnore(AttributeUtils.java:309)
 at org.apache.directory.server.core.schema.SchemaService.assertAllAttributesAllowed(SchemaService.java:1806)
 at org.apache.directory.server.core.schema.SchemaService.check(SchemaService.java:1624)
 at org.apache.directory.server.core.schema.SchemaService.add(SchemaService.java:1636)
 at org.apache.directory.server.core.interceptor.InterceptorChain$Entry$1.add(InterceptorChain.java:1181)
 ... 130 more

If you change the BasicAttributes() constructor call to:

            Attributes attrs = new BasicAttributes( true );

it works fine.

This issue means we cannot use DS 1.0.2.  Should I raise a JIRA entry yet or should I hold
off until you guys have had chance to check my findings?

Many Thanks

SimonT
Mime
View raw message