directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefan Seelmann (JIRA)" <>
Subject [jira] [Commented] (DIRSERVER-1810) Test case fails permanently
Date Thu, 23 May 2013 21:59:21 GMT


Stefan Seelmann commented on DIRSERVER-1810:

The problem is that the modification is not replicated to the consumer.

I enabled debug log for PROVIDER_LOG and CONSUMER_LOG (those feature specific loggers are
very useful btw :) and made the following observation: When the test fails I see that after
10 seconds (and after the modification are done in the provider server) the provider creates
the following log:

[23:12:30] DEBUG [] - updating the details of replica
ReplicaEventLog [hostName=localhost.localdomain, searchFilter=(objectClass=*), lastSentCsn=20130523211220.318000Z#000000#000#000000,
searchCriteria=Notification criteria : 'dc=example,dc=com', '(objectClass=*:[1])', 'sub',
'NEVER_DEREF_ALIASES', 'ALL EVENTS', replicaId=1, refreshNPersist=true, maxInactivePeriod=172800,
purgeThresholdCount=10000, journalFile=/tmp/server-work-provider-replication/syncrepl-data/REPL_EVENT_LOG.1,
dirty=true, consumerEntryDn=ads-dsReplicaId=1,ou=consumers,ou=system]
[23:12:30] DEBUG [] - updated the LastSentCSN of
consumer entry ads-dsReplicaId=1,ou=consumers,ou=system

The first log statement is written from SyncReplRequestHandler.storeReplicaInfo() which is
called from a Runnable running within the "consumerInfoUpdateThread" in a endless loop with
a sleep of 10 seconds.

So I added a 
    Thread.sleep( 10000 );
to the end of the setUp() method of the test class. The effect is that the above log records
is written *before* the modification is done in the provider server, and the test passes.

To be honest I have no idea what the storeReplicaInfo() method does. But I think it is clear
that there is some timeing issue. I also don't know if there is a potential problem that changes
are not replicated (and lost?) when there are modifications between the connect time of the
consumer and the call of storeReplicaInfo()?

> Test case
fails permanently
> ---------------------------------------------------------------------------------------------------------
>                 Key: DIRSERVER-1810
>                 URL:
>             Project: Directory ApacheDS
>          Issue Type: Bug
>            Reporter: Pierre-Arnaud Marcelot
>            Priority: Blocker
>             Fix For: 2.0.0-RC1
> Test case
fails permanently on my machine via Maven *and* in Eclipse.
> I ignored it until we find a fix.
> Here's the error:
> java.lang.AssertionError
> 	at
> 	at org.junit.Assert.assertTrue(
> 	at org.junit.Assert.assertTrue(
> 	at
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(
> 	at java.lang.reflect.Method.invoke(
> 	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(
> 	at
> 	at org.junit.runners.model.FrameworkMethod.invokeExplosively(
> 	at org.junit.internal.runners.statements.InvokeMethod.evaluate(
> 	at$1$
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(
> 	at java.util.concurrent.ThreadPoolExecutor$
> 	at

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message