[jboss-jira] [JBoss JIRA] Commented: (JBAS-7695) org.jboss.test.naming.test.SimpleUnitTestCase fails on Mac OS

Brian Stansberry (JIRA) jira-events at lists.jboss.org
Sat Feb 13 08:50:26 EST 2010


    [ https://jira.jboss.org/jira/browse/JBAS-7695?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12514338#action_12514338 ] 

Brian Stansberry commented on JBAS-7695:
----------------------------------------

Testing confirms that adding the setInterface call fixes this problem. The exact reason it fails isn't clear. The problem is the AS doesn't receive the multicast discovery message, not that the client doesn't receive the UDP unicast response. It's not a issue of multicast routing between two interfaces in the machine itself; the overall testsuite does all sorts of multicast communication between two ASs bound to different interfaces. Further, you can bind the AS to localhost and configure the client to use jnp.localAddress=<default_address> and it will work fine.

http://developer.apple.com/mac/library/documentation/Darwin/Reference/ManPages/man4/ip.4.html makes it clear that without calling setInterface, the socket will use the default interface for sending, even if it is bound to lo. It appears there is some problem with this in the OS X JVMs, i.e. the datagram is not successfully sent. With the missing call to setInterface added, things work correctly.

> org.jboss.test.naming.test.SimpleUnitTestCase fails on Mac OS
> -------------------------------------------------------------
>
>                 Key: JBAS-7695
>                 URL: https://jira.jboss.org/jira/browse/JBAS-7695
>             Project: JBoss Application Server
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: jnpserver
>            Reporter: Brian Stansberry
>            Assignee: Brian Stansberry
>             Fix For: 5.1.0.Beta1
>
>
> Test methods testHaPartitionName and testDiscoveryPort fail on Mac OS in the default situation where ant property "node0" is localhost. If you configure -Dnode0=<the_default_address> it passes.
> I suspect this is because org.jnp.interfaces.NamingContext.discoverServer() is not calling MulticastSocket.setInterface() when jnp.localAddress is set. I need to understand the exact cause of the failure though, as other multicast-based communication (e.g. all the tests in the tests-clustering target) work fine with node0=localhost.

-- 
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