| org.apache.catalina.ant.jmx.JMXAccessorTask org.apache.catalina.ant.jmx.JMXAccessorQueryTask
JMXAccessorQueryTask | public class JMXAccessorQueryTask extends JMXAccessorTask (Code) | | Query for Mbeans.
- open no existing JSR 160 rmi jmx connection
- Get all Mbeans attributes
- Get only the Query Mbeans ObjectNames
- Show query result as Ant console log
- Bind query result as Ant properties
Query a list of Mbeans.
<jmxQuery
host="127.0.0.1"
port="9014"
name="Catalina:type=Manager,*
resultproperty="manager" />
with attribute attributebinding="true" you can get
all attributes also from result objects.
The poperty manager.lenght show the size of the result
and with manager.[0..lenght].name the
resulted ObjectNames are saved.
These tasks require Ant 1.6 or later interface.
author: Peter Rossbach version: $Revision: 467222 $ $Date: 2006-10-24 05:17:11 +0200 (mar., 24 oct. 2006) $ since: 5.5.10 |
bindAttributes | protected void bindAttributes(MBeanServerConnection jmxServerConnection, String resultproperty, String pname, ObjectName oname)(Code) | | Parameters: jmxServerConnection - Parameters: resultproperty - Parameters: pname - Parameters: oname - |
getInfo | public String getInfo()(Code) | | Return descriptive information about this implementation and the
corresponding version number, in the format
<description>/<version> .
|
isAttributebinding | public boolean isAttributebinding()(Code) | | Returns the attributebinding. |
jmxExecute | public String jmxExecute(MBeanServerConnection jmxServerConnection) throws Exception(Code) | | Execute the specified command, based on the configured properties. The
input stream will be closed upon completion of this task, whether it was
executed successfully or not.
exception: Exception - if an error occurs |
jmxQuery | protected String jmxQuery(MBeanServerConnection jmxServerConnection, String qry)(Code) | | Call Mbean server for some mbeans with same domain, attributes.
with attributebindung=true you can save all attributes from all found objects
as your ant properties
Parameters: jmxServerConnection - Parameters: qry - The query result |
setAttributebinding | public void setAttributebinding(boolean attributeBinding)(Code) | | Parameters: attributeBinding - The attributebinding to set. |
Methods inherited from org.apache.catalina.ant.jmx.JMXAccessorTask | public static MBeanServerConnection accessJMXConnection(Project project, String url, String host, String port, String username, String password, String refId) throws MalformedURLException, IOException(Code)(Java Doc) protected Object convertStringToType(String value, String valueType)(Code)(Java Doc) public static MBeanServerConnection createJMXConnection(String url, String host, String port, String username, String password) throws MalformedURLException, IOException(Code)(Java Doc) protected void createProperty(Object result)(Code)(Java Doc) protected void createProperty(String propertyPrefix, Object result)(Code)(Java Doc) protected void echoResult(String name, Object result)(Code)(Java Doc) public void execute() throws BuildException(Code)(Java Doc) public String getDelimiter()(Code)(Java Doc) public String getHost()(Code)(Java Doc) public String getIf()(Code)(Java Doc) public String getInfo()(Code)(Java Doc) protected MBeanServerConnection getJMXConnection() throws MalformedURLException, IOException(Code)(Java Doc) public String getName()(Code)(Java Doc) public String getPassword()(Code)(Java Doc) public String getPort()(Code)(Java Doc) public Map getProperties()(Code)(Java Doc) public String getProperty(String property)(Code)(Java Doc) public String getRef()(Code)(Java Doc) public String getResultproperty()(Code)(Java Doc) public String getUnless()(Code)(Java Doc) public String getUrl()(Code)(Java Doc) public String getUsername()(Code)(Java Doc) public boolean isEcho()(Code)(Java Doc) public boolean isSeparatearrayresults()(Code)(Java Doc) public boolean isUseRef()(Code)(Java Doc) public String jmxExecute(MBeanServerConnection jmxServerConnection) throws Exception(Code)(Java Doc) public void setDelimiter(String separator)(Code)(Java Doc) public void setEcho(boolean echo)(Code)(Java Doc) public void setHost(String host)(Code)(Java Doc) public void setIf(String c)(Code)(Java Doc) public void setName(String objectName)(Code)(Java Doc) public void setPassword(String password)(Code)(Java Doc) public void setPort(String port)(Code)(Java Doc) public boolean setProperty(String property, Object value)(Code)(Java Doc) public void setRef(String refId)(Code)(Java Doc) public void setResultproperty(String propertyName)(Code)(Java Doc) public void setSeparatearrayresults(boolean separateArrayResults)(Code)(Java Doc) public void setUnless(String c)(Code)(Java Doc) public void setUrl(String url)(Code)(Java Doc) public void setUsername(String username)(Code)(Java Doc) protected boolean testIfCondition()(Code)(Java Doc) protected boolean testUnlessCondition()(Code)(Java Doc)
|
|
|