mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

gbellato
31.21.2007 7d707268291c0ab54d36780248f5252dc16c3970
refs
author gbellato <gbellato@localhost>
Wednesday, January 31, 2007 18:21 +0100
committer gbellato <gbellato@localhost>
Wednesday, January 31, 2007 18:21 +0100
commit7d707268291c0ab54d36780248f5252dc16c3970
tree 04020519f663e37a28ebd9518928037b3a537c5e tree | zip | gz
parent 9838bd11aeab5f9eef13001c29ea62d6e6082d10 view | diff
Fix for Issue 1162 : Synchronization server deadlock when using multiple masters and max delay feature

When using multiple masters and configuring the server for maxSendDelays the
synchronization server sometimes stop all activities and never resume it.

The problem was a deadlock between the max delays mechanism and the protocol window mechanism.

This deadlock occurs because the reader threads of the synchronization server are blocked when
the maximum configured delay is reached ans therefore can't process
the WindowMessages anymore.

The solution is not to block the reader thread anymore but to stop sending Window messages to
block the servers that are creating too much delay.

The writer thread then need to check if it is necessary to send again Window messages when
their queue become smaller than the configured threshold.

This fix allows to pass the test :
org.opends.server.stcnhronization.changelog.ChangelogTest.MultipleWriterMultipleReader
This commit therefore also enable this test.
4 files modified
157 ■■■■■ changed files
opends/src/server/org/opends/server/synchronization/changelog/ChangelogCache.java 85 ●●●● diff | view | raw | blame | history
opends/src/server/org/opends/server/synchronization/changelog/ServerHandler.java 67 ●●●●● diff | view | raw | blame | history
opends/src/server/org/opends/server/synchronization/changelog/ServerReader.java 3 ●●●● diff | view | raw | blame | history
opends/tests/unit-tests-testng/src/server/org/opends/server/synchronization/changelog/ChangelogTest.java 2 ●●● diff | view | raw | blame | history