public class MBeanResourceDiscoveryComponent<T extends JMXComponent<?>> extends Object implements ResourceDiscoveryComponent<T>
ObjectNameQueryUtility. Also, setting default
configurations values for nameTemplate and descriptionTemplate according to the message format also defined by
ObjectNameQueryUtility also lets you customize the detected resources name and description according to a
variable replacement strategy. Additionally, any mapped variables found will be set as configuration properties in
their own right.| Modifier and Type | Field and Description |
|---|---|
protected ResourceDiscoveryContext<T> |
discoveryContext |
static String |
PROPERTY_DESCRIPTION_TEMPLATE
Not required when using this discovery component.
|
static String |
PROPERTY_NAME_TEMPLATE
Not required when using this discovery component.
|
static String |
PROPERTY_OBJECT_NAME
Required when using this discovery component.
|
| Constructor and Description |
|---|
MBeanResourceDiscoveryComponent() |
| Modifier and Type | Method and Description |
|---|---|
Set<DiscoveredResourceDetails> |
discoverResources(ResourceDiscoveryContext<T> context) |
Set<DiscoveredResourceDetails> |
discoverResources(ResourceDiscoveryContext<T> context,
boolean skipUnknownProps)
Same as
#discoverResources(ResourceDiscoveryContext with additional param. |
protected org.mc4j.ems.connection.bean.EmsBean |
loadBean(T context,
String objectName)
Loads the bean with the given object name.
|
Set<DiscoveredResourceDetails> |
performDiscovery(org.rhq.core.domain.configuration.Configuration pluginConfiguration,
JMXComponent parentResourceComponent,
org.rhq.core.domain.resource.ResourceType resourceType)
Performs the actual discovery through MBeans.
|
Set<DiscoveredResourceDetails> |
performDiscovery(org.rhq.core.domain.configuration.Configuration pluginConfiguration,
JMXComponent parentResourceComponent,
org.rhq.core.domain.resource.ResourceType resourceType,
boolean skipUnknownProps)
Performs the actual discovery through MBeans.
|
public static final String PROPERTY_OBJECT_NAME
public static final String PROPERTY_NAME_TEMPLATE
public static final String PROPERTY_DESCRIPTION_TEMPLATE
PROPERTY_NAME_TEMPLATE, unique descriptions
can be generated per resource using this template.protected ResourceDiscoveryContext<T extends JMXComponent<?>> discoveryContext
public Set<DiscoveredResourceDetails> discoverResources(ResourceDiscoveryContext<T> context)
discoverResources in interface ResourceDiscoveryComponent<T extends JMXComponent<?>>public Set<DiscoveredResourceDetails> discoverResources(ResourceDiscoveryContext<T> context, boolean skipUnknownProps)
#discoverResources(ResourceDiscoveryContext) with additional param.skipUnknownProps - if true, skip over MBeans that have unknown properties in their ObjectNamepublic Set<DiscoveredResourceDetails> performDiscovery(org.rhq.core.domain.configuration.Configuration pluginConfiguration, JMXComponent parentResourceComponent, org.rhq.core.domain.resource.ResourceType resourceType)
pluginConfiguration - plugin configuration for the resource type being discovered; used to grab values
that govern the MBean query and resource details generationparentResourceComponent - parent resource of the resource being discoveredresourceType - type of resource being discoveredpublic Set<DiscoveredResourceDetails> performDiscovery(org.rhq.core.domain.configuration.Configuration pluginConfiguration, JMXComponent parentResourceComponent, org.rhq.core.domain.resource.ResourceType resourceType, boolean skipUnknownProps)
pluginConfiguration - plugin configuration for the resource type being discovered; used to grab values
that govern the MBean query and resource details generationparentResourceComponent - parent resource of the resource being discoveredresourceType - type of resource being discoveredskipUnknownProps - Should we skip over MBeans that have unknown properties in their ObjectNameCopyright © 2008-2013 Red Hat, Inc.. All Rights Reserved.