Re: LookupDiscovery MulticastTimeToLive

Dan Creswell <[email protected]>
Newsgroups gmane.comp.java.sun.jini
Message-ID <[email protected]>
Hi Rikard,

If you want discovery limited to localhost, is there any reason why you
aren't using simple unicast lookup?

Second of all, you've asked discovery to make use of your ethernet
interface (eth0) which, by implication, means you'll be looking for
traffic on the local subnet not just localhost.

Thirdly, setting multicast TTL to zero means packets (assuming
appropriate network configuration) won't make it outside of the current
subnet - i.e. past the first router they hit.  Basically, setting TTL to
zero will not stop machines on the same subnet as yours from seeing packets.

As Mark has said, you could simply use separate groups etc but this may
not be appropriate.  I would recommend that you tell us what it is you
are trying to achieve after which we can suggest the appropriate remedy.

Hope that helps,

Dan.

Rikard Elofsson wrote:
> Still trouble with this one.
>
> Both my LookupDiscovery config and my Reggie config now include the
> thing below, should work? (I want discovery to be confined to localhost)
> I still find services on my colleauges computers and they find mine so
> it is extremely confusing to work right now ;-)
>
> //Rikard
>
>
> net.jini.discovery.LookupDiscovery {
>        multicastInterfaces = new NetworkInterface[]
> {NetworkInterface.getByName("eth0")};
>        discoveryConstraints =
>        new BasicMethodConstraints(
>                        new MethodDesc[] {
>                        new MethodDesc(
>                                "multicastRequest",
>                                new InvocationConstraints(new
> InvocationConstraint[]{
> new MulticastTimeToLive(0)}, null)),
>                        new MethodDesc(
>                                "multicastAnnouncement",
>                                new InvocationConstraints(new
> InvocationConstraint[]{new MulticastTimeToLive(0)}, null))
>             }
>        );
> }
>
> --------------------------------------------------------------------------
> Getting Started:     http://www.jini.org/wiki/Category:Getting_Started
> Community Web Site:  http://jini.org
> jini-users Archive:  http://archives.java.sun.com/archives/jini-users.html
> Unsubscribing:       email "signoff JINI-USERS"  to [email protected]
>

--------------------------------------------------------------------------
Getting Started:     http://www.jini.org/wiki/Category:Getting_Started
Community Web Site:  http://jini.org
jini-users Archive:  http://archives.java.sun.com/archives/jini-users.html
Unsubscribing:       email "signoff JINI-USERS"  to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.