VMware GemFire Java API Reference
Interface Agent
-
@Deprecated public interface Agent
Deprecated.as of 7.0 use themanagementpackage insteadA server component that provides administration-related information about a GemFire distributed system via the Java Management Extension JMX API. When a JMXAgentis created, it registers an MBean that representsitself. Click here for a description of the attributes, operations, and notifications of this and other GemFire JMX MBeans.The GemFire JMX Agent currently supports three JMX "adapters" through which clients can access the GemFire management beans: an "HTTP adapter" that allows a web browser client to view and modify management beans via HTTP or HTTPS, an "RMI adapter" that allows Java programs to access management beans using Remote Method Invocation, and an "SNMP adapter" that allows SNMP to access management beans. Information about configuring these adapters can be found in
AgentConfig.In most distributed caching architectures, JMX administration agents are run in their own processes. A stand-alone JMX agent is managed using the
agentcommand line utility:$ agent start
This class allows a GemFire application VM to host a JMX management agent. Architectures with "co-located" JMX agents reduce the number of overall proceses required. However, hosting a JMX management agent in the same VM as a GemFire application is not generally recommended because it adds extra burden to an application VM and in the event that the application VM exits the administration information will no longer be available.- Since:
- GemFire 4.0
- See Also:
AgentConfig,AgentFactory
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description ObjectNameconnectToSystem()Deprecated.Connects to the distributed system described by thisAgent's configuration.voiddisconnectFromSystem()Deprecated.Disconnects this agent from the distributed system and unregisters the management beans that provided information about it.AgentConfiggetConfig()Deprecated.Returns the configuration object for this JMX Agent.AdminDistributedSystemgetDistributedSystem()Deprecated.Returns theAdminDistributedSystemthat underlies this JMXAgentornullis this agent is not connected.LogWritergetLogWriter()Deprecated.Returns theLogWriterused for logging information.MBeanServergetMBeanServer()Deprecated.Returns the JMXMBeanServerwith which GemFire MBeans are registered ornullif thisAgentis not started.ObjectNamegetObjectName()Deprecated.Returns theObjectNameof the JMX management bean that represents this agent ornullif thisAgenthas not been started.booleanisConnected()Deprecated.Returns whether or not this JMXAgentis currently providing information about a distributed system.ObjectNamemanageDistributedSystem()Deprecated.Returns the object name of the JMX MBean that represents the distributed system administered by thisAgentornullif thisAgenthas not connected to the distributed system.voidsaveProperties()Deprecated.Saves the configuration for thisAgentto the file specified by @link AgentConfig#getPropertyFile.voidstart()Deprecated.Starts this JMX Agent and its associated adapters.voidstop()Deprecated.Disconnects from the distributed system and stops this JMX Agent and all of its associated adapters.
-
-
-
Field Detail
-
JNDI_NAME
static final String JNDI_NAME
Deprecated.Lookup name for RMIConnector when rmi-registry-enabled is true- See Also:
- Constant Field Values
-
-
Method Detail
-
getConfig
AgentConfig getConfig()
Deprecated.Returns the configuration object for this JMX Agent.- Returns:
- the configuration object for this JMX Agent
-
start
void start()
Deprecated.Starts this JMX Agent and its associated adapters. This method does not connect to the distributed system.
-
getMBeanServer
MBeanServer getMBeanServer()
Deprecated.Returns the JMXMBeanServerwith which GemFire MBeans are registered ornullif thisAgentis not started.- Returns:
- the JMX
MBeanServerwith which GemFire MBeans are registered
-
stop
void stop()
Deprecated.Disconnects from the distributed system and stops this JMX Agent and all of its associated adapters.
-
getObjectName
ObjectName getObjectName()
Deprecated.Returns theObjectNameof the JMX management bean that represents this agent ornullif thisAgenthas not been started.- Returns:
- the
ObjectNameof the JMX management bean that represents this agent
-
isConnected
boolean isConnected()
Deprecated.Returns whether or not this JMXAgentis currently providing information about a distributed system.- Returns:
- whether or not this JMX
Agentis currently providing information about a distributed system.
-
connectToSystem
ObjectName connectToSystem() throws AdminException, MalformedObjectNameException
Deprecated.Connects to the distributed system described by thisAgent's configuration.- Returns:
- The object name of the system that the
Agentis now connected to. - Throws:
AdminException- if an exception is encountered while connectingMalformedObjectNameException- if the format of an MBean name specified in the configuration does not correspond to a valid ObjectName
-
getDistributedSystem
AdminDistributedSystem getDistributedSystem()
Deprecated.Returns theAdminDistributedSystemthat underlies this JMXAgentornullis this agent is not connected.- Returns:
- the
AdminDistributedSystemthat underlies this JMXAgent
-
manageDistributedSystem
ObjectName manageDistributedSystem() throws MalformedObjectNameException
Deprecated.Returns the object name of the JMX MBean that represents the distributed system administered by thisAgentornullif thisAgenthas not connected to the distributed system.- Returns:
- the object name of the JMX MBean that represents the distributed system administered by
this
Agent - Throws:
MalformedObjectNameException- if the format of the JMX MBean name does not correspond to a valid ObjectName
-
disconnectFromSystem
void disconnectFromSystem()
Deprecated.Disconnects this agent from the distributed system and unregisters the management beans that provided information about it. However, this agent's adapters are not stopped and it is possible to reconfigure thisAgentto connect to another distributed system.
-
saveProperties
void saveProperties()
Deprecated.Saves the configuration for thisAgentto the file specified by @link AgentConfig#getPropertyFile.
-
getLogWriter
LogWriter getLogWriter()
Deprecated.Returns theLogWriterused for logging information.- Returns:
- the
LogWriterused for logging information
-
-