[ http://issues.apache.org/jira/browse/DIRSERVER-783?page=all ]

Ate Douma updated DIRSERVER-783:
--------------------------------

    Attachment: AddingAnotherValueToAnAttribute.java
                apacheds-stderr.log
                apacheds-stdout.log

Thanks for following up Stefan.

At first, I couldn't reproduce the problem with your testcase until I made a 
small modification.
In your testcase your create the entry with the description attribute and then 
add 2 more values.
But, if you first create the entry *without* the description attribute and 
thereafter add the three values for the description attribute, the problem 
surfaces:

junit.framework.AssertionFailedError: expected:<3> but was:<5>
        at junit.framework.Assert.fail(Assert.java:47)
        at junit.framework.Assert.failNotEquals(Assert.java:282)
        at junit.framework.Assert.assertEquals(Assert.java:64)
        at junit.framework.Assert.assertEquals(Assert.java:201)
        at junit.framework.Assert.assertEquals(Assert.java:207)
        at 
add.AddingAnotherValueToAnAttribute.testAddAnotherValueToAnAttribute(AddingAnotherValueToAnAttribute.java:100)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at junit.framework.TestCase.runTest(TestCase.java:154)
        at junit.framework.TestCase.runBare(TestCase.java:127)
        at junit.framework.TestResult$1.protect(TestResult.java:106)
        at junit.framework.TestResult.runProtected(TestResult.java:124)
        at junit.framework.TestResult.run(TestResult.java:109)
        at junit.framework.TestCase.run(TestCase.java:118)
        at junit.framework.TestSuite.runTest(TestSuite.java:208)
        at junit.framework.TestSuite.run(TestSuite.java:203)
        at 
org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:128)
        at 
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
        at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
        at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
        at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
        at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)

I've attached the modified testcase as well as the apacheds-stdout.log which 
clearly shows what happened.
I also noticed the apacheds-stderr.log contains two error messages: "jsvc.exec 
error: syscall failed in set_caps"
Maybe that's related to this issue?

Finally, for completeness, this is the ldif export after the testcase:

dn: dc=example,dc=com
dc: example
objectclass: top
objectclass: domain
objectclass: extensibleObject

dn: cn=Fiona Apple, dc=example,dc=com
objectclass: person
objectclass: top
description: an American singer-songwriter
description: Grammy award winning
description: Grammy award winning
description: MTV Music Award winning
description: MTV Music Award winning
sn: Apple
cn: Fiona Apple

Hopefully you will be able to reproduce this problem now too.

> Adding another value to an attribute results in the value to be added twice
> ---------------------------------------------------------------------------
>
>                 Key: DIRSERVER-783
>                 URL: http://issues.apache.org/jira/browse/DIRSERVER-783
>             Project: Directory ApacheDS
>          Issue Type: Bug
>    Affects Versions: 1.0
>         Environment: Ubuntu 6.06, Java 1.5, Jetspeed-2
>            Reporter: Ate Douma
>            Priority: Blocker
>         Attachments: AddingAnotherValueToAnAttribute.java, 
> AddingAnotherValueToAnAttribute.java, apacheds-stderr.log, apacheds-stdout.log
>
>
> If I add a new attribute to a class, its value is stored fine.
> But, if I thereafter add another value for the same attribute, this value is 
> added twice.
> I encountered this with Jetspeed-2 ldap unit tests, but could then easily 
> reproduce this with for instance LDAP Browser\Editor v.2.8.2

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to