[jboss-jira] [JBoss JIRA] Updated: (JGRP-761) Fix NAKACK unit test
Bela Ban (JIRA)
jira-events at lists.jboss.org
Wed Sep 10 07:28:39 EDT 2008
[ https://jira.jboss.org/jira/browse/JGRP-761?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Bela Ban updated JGRP-761:
--------------------------
Fix Version/s: 2.7
> Fix NAKACK unit test
> --------------------
>
> Key: JGRP-761
> URL: https://jira.jboss.org/jira/browse/JGRP-761
> Project: JGroups
> Issue Type: Task
> Affects Versions: 2.6.2
> Reporter: Richard Achmatowicz
> Assignee: Richard Achmatowicz
> Priority: Minor
> Fix For: 2.7
>
>
> The pbcast.NAKACK protocol provides reliable transmission of multicast messages in a group, guaranteeing that for each receiver, all messages received from a given remote peer will be FIFO ordered.
> The NakAckTest makes use of the ProtocolTester class to test pbcast.NAKACK while sandwiched between two Protocol layers: a test harness protocol layer , used to send messages into and receive messages from pbcast.NAKACK, and a LOOPBACK layer used as transport.
> This test has a couple of problems at the moment:
> (i) the test simulates the sending of messages from one peer only, thus not adequately testing the peer by peer FIFO ordering property ;
> (ii) the logic used to check the correct FIFO ordering of messages works for the case of one peer but will break in the case of multiple peers
> For the correctness check, instead of checking that, for each peer, the sequence number received from that peer is one greater than the previous
> sequence number received from that peer, it compares the sequence number received from any peer against a single value called highest_seqno -
> effectively checking that when messages arrive from peers, they are totally ordered. This is too strong a guarantee and should be changed.
> I've also noticed that we have two mechanisms for testing protocols in isolation: ProtocolTester and Simulator. I assume that ProtocolTester is a precursor to Simulator. Was the use of ProtocolTester the reason why
> only one peer was used? Should this test also be converted to use Simulator? As described in the wiki (http://wiki.jboss.org/wiki/JGroupsSimulator) there is lots of potential for using Simulator to model failures at the transport level, which would improve the unit testing of protocols.
> Comments from Bela:
> We should get rid of one of the two (probably ProtocolTester, as you said), and focus on building out the other.
> Yes, looks like that test is flawed. +1 on creating the JIRA issue, which should fix the test code, and possibly port it to Simulator from ProtocolTester.
> Yes, the idea was to use Simulator as a way of sandwiching one or more protocols between Simulator and LOOPBACK (might be a good chance to see if we can trash that one too, and use SHARED_LOOPBACK instead !), inject a number of inputs (ie. messages) and compare the output to expected output.
--
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
More information about the jboss-jira
mailing list