Cluster config setting to disable jmx, see #2531
This commit is contained in:
parent
7b06ee5705
commit
068335789c
5 changed files with 12 additions and 3 deletions
|
|
@ -160,8 +160,11 @@ class Cluster(val system: ExtendedActorSystem) extends Extension {
|
|||
|
||||
system.registerOnTermination(shutdown())
|
||||
|
||||
private val clusterJmx = new ClusterJmx(this, log)
|
||||
clusterJmx.createMBean()
|
||||
private val clusterJmx: Option[ClusterJmx] = {
|
||||
val jmx = new ClusterJmx(this, log)
|
||||
jmx.createMBean()
|
||||
Some(jmx)
|
||||
}
|
||||
|
||||
log.info("Cluster Node [{}] - has started up successfully", selfAddress)
|
||||
|
||||
|
|
@ -237,7 +240,7 @@ class Cluster(val system: ExtendedActorSystem) extends Extension {
|
|||
|
||||
scheduler.close()
|
||||
|
||||
clusterJmx.unregisterMBean()
|
||||
clusterJmx foreach { _.unregisterMBean() }
|
||||
|
||||
log.info("Cluster Node [{}] - Cluster node successfully shut down", selfAddress)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue