NAKACK/UNICAST: replace locks with AtomicBoolean variables
----------------------------------------------------------
Key: JGRP-935
URL:
https://jira.jboss.org/jira/browse/JGRP-935
Project: JGroups
Issue Type: Feature Request
Reporter: Bela Ban
Assignee: Bela Ban
Fix For: 2.8
Instead of acquiring a lock on the sender window of a message, we try to set an
AtomicBoolean var in a CAS operation. Whoever succeeds in setting the var, continues to
remove as many messages as possible. Everybody else returns to the thread pool.
The {setting of the AtomicBoolean var and the removal} and {addition} of messages are
atomic with respect to each other, ie. the NakreceiverWindow.remove() method has a lock
(also to be acquired by add()) when removing a message and setting the AtomicBoolean to
false if no message could be removed.
MOTIVATION: we don't need AtomicBoolean vars *and* locks. Removing locks should result
in a small speed improvement
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira