Other part of code has no access to broadcast loop and have to use
provided static methods
startDiscoveryService
and stopDiscoveryService
startDiscoveryService could be called multiple
times as it stops the running service if it is necessary.
Call to stopDiscoveryService
ignored if service isn't run.
System properties below could be used to control broadcast loop behavior. Property below have to be set explicitly in command line. It's not possible to set it in management.config file. Careless changes of these properties could lead to security or network issues.
null parameters values are filtered out on JdpPacketWriter level and
corresponding keys are not placed to packet.
| Modifier and Type | Class and Description |
|---|---|
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private static JdpController. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| private static InetAddress | |
| private static int | |
| private static Long | |
| public static synchronized void | startDiscoveryService(InetAddress
- multicast group address address, int - udp port to use port, String - name of running JVM instance instanceName, String - JMX service url url)Starts discovery service |
| public static synchronized void | stopDiscoveryService()
Stop running discovery service, it's safe to attempt to stop not started service |
| controller | back to summary |
|---|---|
| private static JdpController. | |
| JdpController | back to summary |
|---|---|
| private JdpController() | |
| getInetAddress | back to summary |
|---|---|
| private static InetAddress getInetAddress(String val, InetAddress dflt, String msg) throws JdpException | |
| getInteger | back to summary |
|---|---|
| private static int getInteger(String val, int dflt, String msg) throws JdpException | |
| getProcessId | back to summary |
|---|---|
| private static Long getProcessId() | |
| startDiscoveryService | back to summary |
|---|---|
| public static synchronized void startDiscoveryService(InetAddress address, int port, String instanceName, String url) throws IOException, JdpException Starts discovery service
| |
| stopDiscoveryService | back to summary |
|---|---|
| public static synchronized void stopDiscoveryService() Stop running discovery service, it's safe to attempt to stop not started service | |
| Modifier and Type | Field and Description |
|---|---|
| private final JdpBroadcaster | |
| private final JdpJmxPacket | |
| private final int | |
| private volatile boolean |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public void |
| bcast | back to summary |
|---|---|
| private final JdpBroadcaster bcast | |
| packet | back to summary |
|---|---|
| private final JdpJmxPacket packet | |
| pause | back to summary |
|---|---|
| private final int pause | |
| shutdown | back to summary |
|---|---|
| private volatile boolean shutdown | |
| JDPControllerRunner | back to summary |
|---|---|
| private JDPControllerRunner(JdpBroadcaster bcast, JdpJmxPacket packet, int pause) | |
| run | back to summary |
|---|---|
| public void run() Implements java. Doc from java. Runs this operation.
| |
| stop | back to summary |
|---|---|
| public void stop() | |