Class MulticastRMICacheManagerPeerProvider

  • All Implemented Interfaces:
    CacheManagerPeerProvider

    public final class MulticastRMICacheManagerPeerProvider
    extends RMICacheManagerPeerProvider
    implements CacheManagerPeerProvider
    A peer provider which discovers peers using Multicast.

    Hosts can be in three different levels of conformance with the Multicast specification (RFC1112), according to the requirements they meet.

    1. Level 0 is the "no support for IP Multicasting" level. Lots of hosts and routers in the Internet are in this state, as multicast support is not mandatory in IPv4 (it is, however, in IPv6). Not too much explanation is needed here: hosts in this level can neither send nor receive multicast packets. They must ignore the ones sent by other multicast capable hosts.
    2. Level 1 is the "support for sending but not receiving multicast IP datagrams" level. Thus, note that it is not necessary to join a multicast group to be able to send datagrams to it. Very few additions are needed in the IP module to make a "Level 0" host "Level 1-compliant".
    3. Level 2 is the "full support for IP multicasting" level. Level 2 hosts must be able to both send and receive multicast traffic. They must know the way to join and leave multicast groups and to propagate this information to multicast routers. Thus, they must include an Internet Group Management Protocol (IGMP) implementation in their TCP/IP stack.

    The list of CachePeers is maintained via heartbeats. rmiUrls are looked up using RMI and converted to CachePeers on registration. On lookup any stale references are removed.

    Version:
    $Id$
    Author:
    Greg Luck
    • Field Detail

      • SHORT_DELAY

        protected static final int SHORT_DELAY
        One tenth of a second, in ms
        See Also:
        Constant Field Values
    • Constructor Detail

      • MulticastRMICacheManagerPeerProvider

        public MulticastRMICacheManagerPeerProvider​(CacheManager cacheManager,
                                                    java.net.InetAddress groupMulticastAddress,
                                                    java.lang.Integer groupMulticastPort,
                                                    java.lang.Integer timeToLive,
                                                    java.net.InetAddress hostAddress)
        Creates and starts a multicast peer provider
        Parameters:
        groupMulticastAddress - 224.0.0.1 to 239.255.255.255 e.g. 230.0.0.1
        groupMulticastPort - 1025 to 65536 e.g. 4446
        hostAddress - the address of the interface to use for sending and receiving multicast. May be null.