Class MulticastTransport
- java.lang.Object
-
- org.apache.activemq.util.ServiceSupport
-
- org.apache.activemq.transport.TransportSupport
-
- org.apache.activemq.transport.TransportThreadSupport
-
- org.apache.activemq.transport.udp.UdpTransport
-
- org.apache.activemq.transport.multicast.MulticastTransport
-
public class MulticastTransport extends UdpTransport
A multicast based transport.
-
-
Constructor Summary
Constructors Constructor Description MulticastTransport(OpenWireFormat wireFormat, URI remoteLocation)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
bind(DatagramSocket socket, SocketAddress localAddress)
protected InetSocketAddress
createAddress(URI remoteLocation)
Creates an address from the given URIprotected CommandChannel
createCommandChannel()
protected DatagramHeaderMarshaller
createDatagramHeaderMarshaller()
protected void
doStop(ServiceStopper stopper)
long
getKeepAliveInterval()
protected InetAddress
getMulticastAddress()
protected String
getProtocolName()
protected String
getProtocolUriScheme()
protected MulticastSocket
getSocket()
int
getTimeToLive()
boolean
isLoopBackMode()
void
setKeepAliveInterval(long keepAliveInterval)
void
setLoopBackMode(boolean loopBackMode)
protected void
setSocket(MulticastSocket socket)
void
setTimeToLive(int timeToLive)
-
Methods inherited from class org.apache.activemq.transport.udp.UdpTransport
connect, createCommandDatagramChannel, createLocalAddress, createReplayer, doStart, getBufferPool, getChannel, getCommandChannel, getDatagramSize, getLocalSocketAddress, getMinmumWireFormatVersion, getPeerCertificates, getPort, getReceiveCounter, getRemoteAddress, getReplayBuffer, getReplayStrategy, getSequenceGenerator, getTargetAddress, getWireFormat, isReplayEnabled, isTrace, isUseLocalHost, oneway, oneway, resolveHostName, run, setBufferPool, setChannel, setCommandChannel, setDatagramSize, setMinmumWireFormatVersion, setPeerCertificates, setPort, setReplayBuffer, setReplayEnabled, setReplayStrategy, setSequenceGenerator, setTargetEndpoint, setTrace, setUseLocalHost, toString
-
Methods inherited from class org.apache.activemq.transport.TransportThreadSupport
getStackSize, isDaemon, setDaemon, setStackSize
-
Methods inherited from class org.apache.activemq.transport.TransportSupport
asyncRequest, checkStarted, doConsume, getTransportListener, isConnected, isDisposed, isFaultTolerant, isReconnectSupported, isUpdateURIsSupported, narrow, onException, reconnect, request, request, setTransportListener, updateURIs
-
Methods inherited from class org.apache.activemq.util.ServiceSupport
addServiceListener, dispose, isStarted, isStopped, isStopping, postStop, preStart, removeServiceListener, start, stop
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.apache.activemq.transport.Transport
asyncRequest, getTransportListener, isConnected, isDisposed, isFaultTolerant, isReconnectSupported, isUpdateURIsSupported, narrow, reconnect, request, request, setTransportListener, updateURIs
-
-
-
-
Constructor Detail
-
MulticastTransport
public MulticastTransport(OpenWireFormat wireFormat, URI remoteLocation) throws UnknownHostException, IOException
- Throws:
UnknownHostException
IOException
-
-
Method Detail
-
getKeepAliveInterval
public long getKeepAliveInterval()
-
setKeepAliveInterval
public void setKeepAliveInterval(long keepAliveInterval)
-
isLoopBackMode
public boolean isLoopBackMode()
-
setLoopBackMode
public void setLoopBackMode(boolean loopBackMode)
-
getTimeToLive
public int getTimeToLive()
-
setTimeToLive
public void setTimeToLive(int timeToLive)
-
getProtocolName
protected String getProtocolName()
- Overrides:
getProtocolName
in classUdpTransport
-
getProtocolUriScheme
protected String getProtocolUriScheme()
- Overrides:
getProtocolUriScheme
in classUdpTransport
-
bind
protected void bind(DatagramSocket socket, SocketAddress localAddress) throws SocketException
- Overrides:
bind
in classUdpTransport
- Throws:
SocketException
-
doStop
protected void doStop(ServiceStopper stopper) throws Exception
- Overrides:
doStop
in classUdpTransport
- Throws:
Exception
-
createCommandChannel
protected CommandChannel createCommandChannel() throws IOException
- Overrides:
createCommandChannel
in classUdpTransport
- Throws:
IOException
-
getMulticastAddress
protected InetAddress getMulticastAddress()
-
getSocket
protected MulticastSocket getSocket()
-
setSocket
protected void setSocket(MulticastSocket socket)
-
createAddress
protected InetSocketAddress createAddress(URI remoteLocation) throws UnknownHostException, IOException
Description copied from class:UdpTransport
Creates an address from the given URI- Overrides:
createAddress
in classUdpTransport
- Throws:
UnknownHostException
IOException
-
createDatagramHeaderMarshaller
protected DatagramHeaderMarshaller createDatagramHeaderMarshaller()
- Overrides:
createDatagramHeaderMarshaller
in classUdpTransport
-
-