There are a few tools that can be used to monitor the gateway senders GatewaySenders and receivers GatewayReceivers:
JMX
JMX can be used to receive Geode severe, error or warning log messages as alerts as well as to access GatewaySenderMBean and GatewayReceiverMBean attributes
Alerts
JMX clients can be configured to receive Geode severe, error or warning log messages as alerts using a JMX NotificationListener.
The default is alert level is severe, but it is configurable. To change the alert level, invoke the DistributedSystemMBean changeAlertLevel operation.
Here are examples of modifying the alert level using JConsole and a Java JMX client.
JConsole
To view the alert level:
To change the alert level:
Java
Code Block | ||
---|---|---|
| ||
JMXServiceURL url = new JMXServiceURL("service:jmx:rmi://localhost/jndi/rmi://localhost:1092/jmxrmi"); JMXConnector jmxConnector = JMXConnectorFactory.connect(url); MBeanServerConnection mbs = jmxConnector.getMBeanServerConnection(); ObjectName distributedSystem = new ObjectName("GemFire:service=System,type=Distributed"); mbs.invoke(distributedSystem, "changeAlertLevel", new String[] {"warning"}, new String[] {"java.lang.String"}) |
MBean Attributes
JMX clients can also access GatewaySenderMBean and GatewayReceiverMBean attributes.
Here are some example using JConsole and a Java JMX client.
JConsole
To view GatewaySender attributes:
Java