org.rhq.core.pc
Class PluginContainerConfiguration

java.lang.Object
  extended by org.rhq.core.pc.PluginContainerConfiguration

public class PluginContainerConfiguration
extends Object

Configuration properties for the plugin container and all its internal managers.

Author:
John Mazzitelli

Field Summary
static long AVAILABILITY_SCAN_INITIAL_DELAY_DEFAULT
           
static long AVAILABILITY_SCAN_PERIOD_DEFAULT
           
static long CONFIGURATION_DISCOVERY_INITIAL_DELAY_DEFAULT
           
static long CONFIGURATION_DISCOVERY_PERIOD_DEFAULT
           
static long CONTENT_DISCOVERY_INITIAL_DELAY_DEFAULT
           
static long CONTENT_DISCOVERY_PERIOD_DEFAULT
           
static int CONTENT_DISCOVERY_THREADCOUNT_DEFAULT
           
static long DRIFT_DETECTION_INITIAL_DELAY_DEFAULT
           
static long DRIFT_DETECTION_PERIOD_DEFAULT
           
static int EVENT_REPORT_MAX_PER_SOURCE_DEFAULT
           
static int EVENT_REPORT_MAX_TOTAL_DEFAULT
           
static long EVENT_SENDER_INITIAL_DELAY_DEFAULT
           
static long EVENT_SENDER_PERIOD_DEFAULT
           
static long MEASUREMENT_COLLECTION_INITIAL_DELAY_DEFAULT
           
static int MEASUREMENT_COLLECTION_THREADCOUNT_DEFAULT
           
static long OPERATION_INVOCATION_TIMEOUT_DEFAULT
           
static int OPERATION_INVOKER_THREADCOUNT_DEFAULT
           
static int RESOURCE_FACTORY_CORE_POOL_SIZE_DEFAULT
           
static int RESOURCE_FACTORY_KEEP_ALIVE_DEFAULT
           
static int RESOURCE_FACTORY_MAX_POOL_SIZE_DEFAULT
           
static long SERVER_DISCOVERY_INITIAL_DELAY_DEFAULT
           
static long SERVER_DISCOVERY_PERIOD_DEFAULT
           
static long SERVICE_DISCOVERY_INITIAL_DELAY_DEFAULT
           
static long SERVICE_DISCOVERY_PERIOD_DEFAULT
           
 
Constructor Summary
PluginContainerConfiguration()
           
 
Method Summary
 long getAvailabilityScanInitialDelay()
          Returns the length of time, in seconds, before resource availability scans are started.
 long getAvailabilityScanPeriod()
          Returns the length of time, in seconds, between each availability scan.
 long getConfigurationDiscoveryInitialDelay()
           
 long getConfigurationDiscoveryPeriod()
           
 String getContainerName()
          This is the name of the plugin container, as assigned to it by the software component that is embedding the plugin container.
 long getContentDiscoveryInitialDelay()
          Returns the length of time, in seconds, before auto-discovery of content first begins.
 long getContentDiscoveryPeriod()
          Returns the length of time, in seconds, between each auto-discovery of content.
 int getContentDiscoveryThreadPoolSize()
          This defines the number of threads within the content discovery thread pool.
 File getDataDirectory()
          Returns the directory where the plugins can squirrel away files with data they want to persist.
static String getDefaultClassLoaderFilter()
          Returns the default filter for class loading that is used to prevent leaking of agent / PC classes to plugins.
 List<String> getDisabledPlugins()
          If any plugins are to be disabled (i.e.
 long getDriftDetectionInitialDelay()
          Returns the length of time, in seconds, before drift detection first begins.
 long getDriftDetectionPeriod()
          Returns the length of time, in seconds, between each drift detection scan.
 int getEventReportMaxPerSource()
           
 int getEventReportMaxTotal()
           
 long getEventSenderInitialDelay()
           
 long getEventSenderPeriod()
           
 long getMeasurementCollectionInitialDelay()
          Returns the length of time, in seconds, before measurements begin getting collected.
 int getMeasurementCollectionThreadPoolSize()
          When measurements are scheduled for collection, the collection will be performed by threads from a thread pool.
 long getOperationInvocationTimeout()
          When an operation invocation is made, this is the amount of time, in seconds, that it has to complete before it is aborted.
 int getOperationInvokerThreadPoolSize()
          When an operation is to be invoked, the execution of the operation will be performed by threads from a thread pool.
 PluginContainerDeployment getPluginContainerDeployment()
          Indicates where the plugin container is deployed.
 File getPluginDirectory()
          Returns the directory where all plugin jars can be found.
 PluginFinder getPluginFinder()
          Returns the instance of PluginFinder for the container to use to locate all plugins to be loaded.
 int getResourceFactoryCoreThreadPoolSize()
          Returns the base number of threads in the resource factory task thread pool, effectively defining the number of concurrent resource factory tasks that may take place at the same time.
 int getResourceFactoryKeepAliveTime()
          Returns the resource factory thread pool keep alive time in milliseconds.
 int getResourceFactoryMaxThreadPoolSize()
          Returns the maximum number of threads in the resource factory task thread pool.
 String getRootPluginClassLoaderRegex()
          Returns the regex that defines what classes the plugin container can provide to its plugins from its own classloader and its parents.
 long getServerDiscoveryInitialDelay()
          Returns the length of time, in seconds, before auto-discovery of platforms/servers first begins.
 long getServerDiscoveryPeriod()
          Returns the length of time, in seconds, between each auto-discovery of platforms/servers.
 ServerServices getServerServices()
          Returns the object that contains all the remote POJOs that can be used to send data to the remote server.
 long getServiceDiscoveryInitialDelay()
          Returns the length of time, in seconds, before auto-discovery of services first begins.
 long getServiceDiscoveryPeriod()
          Returns the length of time, in seconds, between each auto-discovery of services.
 File getTemporaryDirectory()
          Returns the directory where the plugins can squirrel away temporary files.
 boolean isCreateResourceClassloaders()
          Returns whether or not the plugin container should create individual classloaders for resources that need that kind of isolation.
 boolean isInsideAgent()
          Returns whether or not the plugin container is running inside an agent, which means it is running external to any managed product.
 void setAvailabilityScanInitialDelay(long period)
          Sets the length of time, in seconds, before resource availability scans first begin.
 void setAvailabilityScanPeriod(long period)
          Sets the length of time, in seconds, between each availability scan.
 void setConfigurationDiscoveryInitialDelay(long delay)
           
 void setConfigurationDiscoveryPeriod(long period)
           
 void setContainerName(String name)
          Defines a name that the container can be known as.
 void setContentDiscoveryInitialDelay(long delay)
          Sets the length of time, in seconds, before auto-discovery of content first begins.
 void setContentDiscoveryPeriod(long period)
          Sets the length of time, in seconds, between each auto-discovery of content.
 void setContentDiscoveryThreadPoolSize(int size)
          Returns the number of threads to use in the content discovery thread pool.
 void setCreateResourceClassloaders(boolean flag)
          Sets the flag to indicate if the plugin container should create individual resource classloaders.
 void setDataDirectory(File dataDir)
          Sets the directory where the plugins can squirrel away files with data they want to persist.
 void setDisabledPlugins(List<String> disabledPlugins)
          If one or more plugins are not to be loaded by the plugin container, the given list should be the names of the plugins to be disabled.
 void setDriftDetectionInitialDelay(long delay)
          Sets the length of time, in seconds, before drift detection first begins.
 void setDriftDetectionPeriod(long period)
          Sets the length of time, in seconds, between each drift detection scan.
 void setEventReportMaxPerSource(int value)
           
 void setEventReportMaxTotal(int value)
           
 void setEventSenderInitialDelay(long delay)
           
 void setEventSenderPeriod(long period)
           
 void setInsideAgent(boolean flag)
          Sets the flag to indicate if the plugin container is inside an external agent or if its embedded in a managed product.
 void setMeasurementCollectionInitialDelay(long period)
          Sets the length of time, in seconds, before measurements begin getting collected.
 void setMeasurementCollectionThreadPoolSize(int size)
          Defines the number of threads that can concurrently collection measurements.
 void setOperationInvocationTimeout(long timeout)
          Sets the default timeout, specified in seconds.
 void setOperationInvokerThreadPoolSize(int size)
          Defines the number of threads that can concurrent execute operations.
 void setPluginDirectory(File pluginDir)
          Sets the location where the plugin jars can be found.
 void setPluginFinder(PluginFinder finder)
          Sets the PluginFinder instance used by the container.
 void setResourceFactoryCoreThreadPoolSize(int size)
          Defines the base number of threads that can concurrently execute resource factory tasks.
 void setResourceFactoryKeepAliveTime(int time)
          Sets the resource factory thread pool keep alive time in milliseconds.
 void setResourceFactoryMaxThreadPoolSize(int size)
          Defines the maximum number of threads that can concurrently execute resource factory tasks.
 void setRootPluginClassLoaderRegex(String regex)
          Sets the regex that defines what classes the plugin container should hide from its plugins.
 void setServerDiscoveryInitialDelay(long period)
          Sets the length of time, in seconds, before auto-discovery of platforms/servers first begins.
 void setServerDiscoveryPeriod(long period)
          Sets the length of time, in seconds, between each auto-discovery of platforms/servers.
 void setServerServices(ServerServices serverServices)
          If the plugin container is contained in an embeddor that has access to a remote server, that embeddor will call this method in order to provide the plugin container with all the remote POJO interfaces exposed by that server.
 void setServiceDiscoveryInitialDelay(long period)
          Sets the length of time, in seconds, before auto-discovery of services first begins.
 void setServiceDiscoveryPeriod(long period)
          Sets the length of time, in seconds, between each auto-discovery of services.
 void setTemporaryDirectory(File tmpDir)
          Sets the directory where the plugins can squirrel away temporary files.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

SERVER_DISCOVERY_INITIAL_DELAY_DEFAULT

public static final long SERVER_DISCOVERY_INITIAL_DELAY_DEFAULT
See Also:
Constant Field Values

SERVER_DISCOVERY_PERIOD_DEFAULT

public static final long SERVER_DISCOVERY_PERIOD_DEFAULT
See Also:
Constant Field Values

SERVICE_DISCOVERY_INITIAL_DELAY_DEFAULT

public static final long SERVICE_DISCOVERY_INITIAL_DELAY_DEFAULT
See Also:
Constant Field Values

SERVICE_DISCOVERY_PERIOD_DEFAULT

public static final long SERVICE_DISCOVERY_PERIOD_DEFAULT
See Also:
Constant Field Values

RESOURCE_FACTORY_CORE_POOL_SIZE_DEFAULT

public static final int RESOURCE_FACTORY_CORE_POOL_SIZE_DEFAULT
See Also:
Constant Field Values

RESOURCE_FACTORY_MAX_POOL_SIZE_DEFAULT

public static final int RESOURCE_FACTORY_MAX_POOL_SIZE_DEFAULT
See Also:
Constant Field Values

RESOURCE_FACTORY_KEEP_ALIVE_DEFAULT

public static final int RESOURCE_FACTORY_KEEP_ALIVE_DEFAULT
See Also:
Constant Field Values

AVAILABILITY_SCAN_INITIAL_DELAY_DEFAULT

public static final long AVAILABILITY_SCAN_INITIAL_DELAY_DEFAULT
See Also:
Constant Field Values

AVAILABILITY_SCAN_PERIOD_DEFAULT

public static final long AVAILABILITY_SCAN_PERIOD_DEFAULT
See Also:
Constant Field Values

MEASUREMENT_COLLECTION_INITIAL_DELAY_DEFAULT

public static final long MEASUREMENT_COLLECTION_INITIAL_DELAY_DEFAULT
See Also:
Constant Field Values

MEASUREMENT_COLLECTION_THREADCOUNT_DEFAULT

public static final int MEASUREMENT_COLLECTION_THREADCOUNT_DEFAULT
See Also:
Constant Field Values

DRIFT_DETECTION_INITIAL_DELAY_DEFAULT

public static final long DRIFT_DETECTION_INITIAL_DELAY_DEFAULT
See Also:
Constant Field Values

DRIFT_DETECTION_PERIOD_DEFAULT

public static final long DRIFT_DETECTION_PERIOD_DEFAULT
See Also:
Constant Field Values

CONTENT_DISCOVERY_INITIAL_DELAY_DEFAULT

public static final long CONTENT_DISCOVERY_INITIAL_DELAY_DEFAULT
See Also:
Constant Field Values

CONTENT_DISCOVERY_PERIOD_DEFAULT

public static final long CONTENT_DISCOVERY_PERIOD_DEFAULT
See Also:
Constant Field Values

CONTENT_DISCOVERY_THREADCOUNT_DEFAULT

public static final int CONTENT_DISCOVERY_THREADCOUNT_DEFAULT
See Also:
Constant Field Values

CONFIGURATION_DISCOVERY_INITIAL_DELAY_DEFAULT

public static final long CONFIGURATION_DISCOVERY_INITIAL_DELAY_DEFAULT
See Also:
Constant Field Values

CONFIGURATION_DISCOVERY_PERIOD_DEFAULT

public static final long CONFIGURATION_DISCOVERY_PERIOD_DEFAULT
See Also:
Constant Field Values

OPERATION_INVOKER_THREADCOUNT_DEFAULT

public static final int OPERATION_INVOKER_THREADCOUNT_DEFAULT
See Also:
Constant Field Values

OPERATION_INVOCATION_TIMEOUT_DEFAULT

public static final long OPERATION_INVOCATION_TIMEOUT_DEFAULT
See Also:
Constant Field Values

EVENT_SENDER_INITIAL_DELAY_DEFAULT

public static final long EVENT_SENDER_INITIAL_DELAY_DEFAULT
See Also:
Constant Field Values

EVENT_SENDER_PERIOD_DEFAULT

public static final long EVENT_SENDER_PERIOD_DEFAULT
See Also:
Constant Field Values

EVENT_REPORT_MAX_PER_SOURCE_DEFAULT

public static final int EVENT_REPORT_MAX_PER_SOURCE_DEFAULT
See Also:
Constant Field Values

EVENT_REPORT_MAX_TOTAL_DEFAULT

public static final int EVENT_REPORT_MAX_TOTAL_DEFAULT
See Also:
Constant Field Values
Constructor Detail

PluginContainerConfiguration

public PluginContainerConfiguration()
Method Detail

getPluginDirectory

public File getPluginDirectory()
Returns the directory where all plugin jars can be found.

Returns:
plugin jar location

setPluginDirectory

public void setPluginDirectory(File pluginDir)
Sets the location where the plugin jars can be found.

Parameters:
pluginDir - plugin jar location

getDataDirectory

public File getDataDirectory()
Returns the directory where the plugins can squirrel away files with data they want to persist.

Returns:
data location

setDataDirectory

public void setDataDirectory(File dataDir)
Sets the directory where the plugins can squirrel away files with data they want to persist.

Parameters:
dataDir - data location

getTemporaryDirectory

public File getTemporaryDirectory()
Returns the directory where the plugins can squirrel away temporary files. This directory may be deleted or cleaned out while the plugin container is down, so plugins cannot assume data they write in this directory will live past the lifetime of the current plugin container instance.

Returns:
temporary directory location

setTemporaryDirectory

public void setTemporaryDirectory(File tmpDir)
Sets the directory where the plugins can squirrel away temporary files.

Parameters:
tmpDir - temporary directory location

getDisabledPlugins

public List<String> getDisabledPlugins()
If any plugins are to be disabled (i.e. not loaded by the plugin container), the plugin names will be returned in a list. If no plugins are to be disabled, and empty list is returned. The returned list is a copy, not the actual list used internally. Note that the plugin name is the name found in the plugin .xml descriptor in the plugin root element.

Returns:
list of plugin names identifying plugins to be disabled

setDisabledPlugins

public void setDisabledPlugins(List<String> disabledPlugins)
If one or more plugins are not to be loaded by the plugin container, the given list should be the names of the plugins to be disabled. Note that the plugin name is the name found in the plugin .xml descriptor in the plugin root element.

Parameters:
disabledPlugins -

getRootPluginClassLoaderRegex

public String getRootPluginClassLoaderRegex()
Returns the regex that defines what classes the plugin container can provide to its plugins from its own classloader and its parents. If not null, any classes found in the plugin container's classloader (and its parent classloaders) that do NOT match this regex will be hidden from the plugins. If null, there are no hidden classes and any class the plugin container's classloader has is visible to all plugins.

Returns:
regular expression (may be null)
See Also:
RootPluginClassLoader

setRootPluginClassLoaderRegex

public void setRootPluginClassLoaderRegex(String regex)
Sets the regex that defines what classes the plugin container should hide from its plugins.

Parameters:
regex - regular expression
See Also:
RootPluginClassLoader

isCreateResourceClassloaders

public boolean isCreateResourceClassloaders()
Returns whether or not the plugin container should create individual classloaders for resources that need that kind of isolation. Typically, this value is the same as the isInsideAgent() flag because usually it is only when running inside an agent do you need to create these classloaders. However, this flag can be set independently of that is-inside-agent flag to support tests.

Returns:
true if the container should create individual classloaders for resources that need them; false if only plugin classloaders are needed, thus assuming the root classloader has all connection classes for any and all managed resources that need to be monitored.

setCreateResourceClassloaders

public void setCreateResourceClassloaders(boolean flag)
Sets the flag to indicate if the plugin container should create individual resource classloaders. See isCreateResourceClassloaders() for more details of what this flag means.

Parameters:
flag -

getAvailabilityScanInitialDelay

public long getAvailabilityScanInitialDelay()
Returns the length of time, in seconds, before resource availability scans are started.

Returns:
number of seconds before availability scans start

setAvailabilityScanInitialDelay

public void setAvailabilityScanInitialDelay(long period)
Sets the length of time, in seconds, before resource availability scans first begin.

Parameters:
period -

getAvailabilityScanPeriod

public long getAvailabilityScanPeriod()
Returns the length of time, in seconds, between each availability scan.

Returns:
number of seconds between each availability scan

setAvailabilityScanPeriod

public void setAvailabilityScanPeriod(long period)
Sets the length of time, in seconds, between each availability scan.

Parameters:
period - number of seconds between each availability scan

getMeasurementCollectionInitialDelay

public long getMeasurementCollectionInitialDelay()
Returns the length of time, in seconds, before measurements begin getting collected.

Returns:
number of seconds

setMeasurementCollectionInitialDelay

public void setMeasurementCollectionInitialDelay(long period)
Sets the length of time, in seconds, before measurements begin getting collected.

Parameters:
period -

getServerDiscoveryInitialDelay

public long getServerDiscoveryInitialDelay()
Returns the length of time, in seconds, before auto-discovery of platforms/servers first begins.

Returns:
number of seconds before each platform/server auto-discovery starts

setServerDiscoveryInitialDelay

public void setServerDiscoveryInitialDelay(long period)
Sets the length of time, in seconds, before auto-discovery of platforms/servers first begins.

Parameters:
period -

getServerDiscoveryPeriod

public long getServerDiscoveryPeriod()
Returns the length of time, in seconds, between each auto-discovery of platforms/servers. In other words, an auto-discovery will run every X seconds, where X is this method's return value.

If this value was never setServerDiscoveryPeriod(long), the default will be SERVER_DISCOVERY_PERIOD_DEFAULT.

Returns:
number of seconds between each platform/server auto-discovery run

setServerDiscoveryPeriod

public void setServerDiscoveryPeriod(long period)
Sets the length of time, in seconds, between each auto-discovery of platforms/servers. In other words, an auto-discovery should be run every period seconds.

Parameters:
period - number of seconds between each platform/server auto-discovery run

getServiceDiscoveryInitialDelay

public long getServiceDiscoveryInitialDelay()
Returns the length of time, in seconds, before auto-discovery of services first begins.

Returns:
number of seconds before each service auto-discovery starts

setServiceDiscoveryInitialDelay

public void setServiceDiscoveryInitialDelay(long period)
Sets the length of time, in seconds, before auto-discovery of services first begins.

Parameters:
period -

getServiceDiscoveryPeriod

public long getServiceDiscoveryPeriod()
Returns the length of time, in seconds, between each auto-discovery of services. In other words, an auto-discovery will run every X seconds, where X is this method's return value.

If this value was never setServiceDiscoveryPeriod(long), the default will be SERVICE_DISCOVERY_PERIOD_DEFAULT.

Returns:
number of seconds between each platform/server auto-discovery run

setServiceDiscoveryPeriod

public void setServiceDiscoveryPeriod(long period)
Sets the length of time, in seconds, between each auto-discovery of services. In other words, an auto-discovery should be run every period seconds.

Parameters:
period - number of seconds between each service auto-discovery run

getPluginFinder

public PluginFinder getPluginFinder()
Returns the instance of PluginFinder for the container to use to locate all plugins to be loaded.

Returns:
PluginFinder instance.

setPluginFinder

public void setPluginFinder(PluginFinder finder)
Sets the PluginFinder instance used by the container.

Parameters:
finder -

getMeasurementCollectionThreadPoolSize

public int getMeasurementCollectionThreadPoolSize()
When measurements are scheduled for collection, the collection will be performed by threads from a thread pool. This defines the number of threads within that thread pool, effectively defining the number of measurements that can be collected concurrently.

Returns:
the size of the thread pool

setMeasurementCollectionThreadPoolSize

public void setMeasurementCollectionThreadPoolSize(int size)
Defines the number of threads that can concurrently collection measurements.

Parameters:
size - the new size of the thread pool

getDriftDetectionInitialDelay

public long getDriftDetectionInitialDelay()
Returns the length of time, in seconds, before drift detection first begins.

Returns:
initial delay in seconds

setDriftDetectionInitialDelay

public void setDriftDetectionInitialDelay(long delay)
Sets the length of time, in seconds, before drift detection first begins.

Parameters:
delay - time in seconds before first drift detection

getDriftDetectionPeriod

public long getDriftDetectionPeriod()
Returns the length of time, in seconds, between each drift detection scan. In other words, a drift detection scan will run every X seconds, where X is this method's return value. If this value was never set via setDriftDetectionPeriod(long), the default will be DRIFT_DETECTION_PERIOD_DEFAULT.

Returns:
time in seconds between drift detection scans

setDriftDetectionPeriod

public void setDriftDetectionPeriod(long period)
Sets the length of time, in seconds, between each drift detection scan. In other words, a drift detection scan should be run every period seconds.

Parameters:
period - time in seconds between drift detection scans

getContentDiscoveryInitialDelay

public long getContentDiscoveryInitialDelay()
Returns the length of time, in seconds, before auto-discovery of content first begins.

Returns:
initial delay in seconds

setContentDiscoveryInitialDelay

public void setContentDiscoveryInitialDelay(long delay)
Sets the length of time, in seconds, before auto-discovery of content first begins.

Parameters:
delay - time in seconds before first auto-discovery

getContentDiscoveryPeriod

public long getContentDiscoveryPeriod()
Returns the length of time, in seconds, between each auto-discovery of content. In other words, an auto-discovery will run every X seconds, where X is this method's return value. If this value was never set via setContentDiscoveryPeriod(long), the default will be CONTENT_DISCOVERY_PERIOD_DEFAULT.

Returns:
time in seconds between auto-discoveries

setContentDiscoveryPeriod

public void setContentDiscoveryPeriod(long period)
Sets the length of time, in seconds, between each auto-discovery of content. In other words, an auto-discovery should be run every period seconds.

Parameters:
period - time in seconds between auto-discoveries

getContentDiscoveryThreadPoolSize

public int getContentDiscoveryThreadPoolSize()
This defines the number of threads within the content discovery thread pool. If this value was never set via setContentDiscoveryThreadPoolSize(int), the default will be CONTENT_DISCOVERY_THREADCOUNT_DEFAULT.

Returns:
number of threads

setContentDiscoveryThreadPoolSize

public void setContentDiscoveryThreadPoolSize(int size)
Returns the number of threads to use in the content discovery thread pool.

Parameters:
size - number of threads

getConfigurationDiscoveryInitialDelay

public long getConfigurationDiscoveryInitialDelay()

setConfigurationDiscoveryInitialDelay

public void setConfigurationDiscoveryInitialDelay(long delay)

getConfigurationDiscoveryPeriod

public long getConfigurationDiscoveryPeriod()

setConfigurationDiscoveryPeriod

public void setConfigurationDiscoveryPeriod(long period)

getOperationInvokerThreadPoolSize

public int getOperationInvokerThreadPoolSize()
When an operation is to be invoked, the execution of the operation will be performed by threads from a thread pool. This defines the number of threads within that thread pool, effectively defining the number of operations that can be invoked concurrently.

Returns:
the size of the thread pool

setOperationInvokerThreadPoolSize

public void setOperationInvokerThreadPoolSize(int size)
Defines the number of threads that can concurrent execute operations.

Parameters:
size - the new size of the thread pool

getOperationInvocationTimeout

public long getOperationInvocationTimeout()
When an operation invocation is made, this is the amount of time, in seconds, that it has to complete before it is aborted. Note that a plugin is free to override this timeout by defining its own in the operation's metadata found in the plugin descriptor.

Returns:
operation timeout, in seconds

setOperationInvocationTimeout

public void setOperationInvocationTimeout(long timeout)
Sets the default timeout, specified in seconds.

Parameters:
timeout -

getEventSenderInitialDelay

public long getEventSenderInitialDelay()

setEventSenderInitialDelay

public void setEventSenderInitialDelay(long delay)

getEventSenderPeriod

public long getEventSenderPeriod()

setEventSenderPeriod

public void setEventSenderPeriod(long period)

getEventReportMaxPerSource

public int getEventReportMaxPerSource()

setEventReportMaxPerSource

public void setEventReportMaxPerSource(int value)

getEventReportMaxTotal

public int getEventReportMaxTotal()

setEventReportMaxTotal

public void setEventReportMaxTotal(int value)

setResourceFactoryCoreThreadPoolSize

public void setResourceFactoryCoreThreadPoolSize(int size)
Defines the base number of threads that can concurrently execute resource factory tasks.

Parameters:
size - new size of the thread pool

getResourceFactoryCoreThreadPoolSize

public int getResourceFactoryCoreThreadPoolSize()
Returns the base number of threads in the resource factory task thread pool, effectively defining the number of concurrent resource factory tasks that may take place at the same time.

Returns:
size of the thread pool

setResourceFactoryMaxThreadPoolSize

public void setResourceFactoryMaxThreadPoolSize(int size)
Defines the maximum number of threads that can concurrently execute resource factory tasks.

Parameters:
size - new maximum size

getResourceFactoryMaxThreadPoolSize

public int getResourceFactoryMaxThreadPoolSize()
Returns the maximum number of threads in the resource factory task thread pool.

Returns:
maximum number of threads

setResourceFactoryKeepAliveTime

public void setResourceFactoryKeepAliveTime(int time)
Sets the resource factory thread pool keep alive time in milliseconds.

Parameters:
time - in milliseconds

getResourceFactoryKeepAliveTime

public int getResourceFactoryKeepAliveTime()
Returns the resource factory thread pool keep alive time in milliseconds.

Returns:
thread pool time in milliseconds

getContainerName

public String getContainerName()
This is the name of the plugin container, as assigned to it by the software component that is embedding the plugin container. This is usually, but doesn't have to be, the fully qualified domain name of the platform where the plugin container is running. Note that if this container name was never explicitly set, the default will be the canonical host name of the platform where this VM is running - and if that default cannot be determine, null will be returned.

Returns:
a name that can be used to uniquely identify the plugin container (will be null if the name is not explicitly configured and it cannot be determined at runtime)

setContainerName

public void setContainerName(String name)
Defines a name that the container can be known as. This is usually the fully qualified domain name that the platform on which this plugin container is running. However, this does not have to be the case; this name can be anything.

Parameters:
name - the plugin container's name

getServerServices

public ServerServices getServerServices()
Returns the object that contains all the remote POJOs that can be used to send data to the remote server. If null, the plugin container is detached from any server and must operate independently.

Returns:
the server-exposed interfaces that can be remotely accessed by the plugin container (may be null)

setServerServices

public void setServerServices(ServerServices serverServices)
If the plugin container is contained in an embeddor that has access to a remote server, that embeddor will call this method in order to provide the plugin container with all the remote POJO interfaces exposed by that server. If null is passed in, the plugin container is be detached from any server.

Parameters:
serverServices - the server-exposed interfaces that can be remotely accessed by the plugin container (may be null)

isInsideAgent

public boolean isInsideAgent()
Returns whether or not the plugin container is running inside an agent, which means it is running external to any managed product. Note: Use getPluginContainerDeployment() instead, this method might get deprecated later.

Returns:
true if the container is deployed inside an external agent process; false if the plugin container is embedded directly in a managed product

getPluginContainerDeployment

public PluginContainerDeployment getPluginContainerDeployment()
Indicates where the plugin container is deployed. This is analogous to the isInsideAgent() except it returns the plugin API enum, rather than a boolean.

Returns:
indicator of where the plugin is deployed

setInsideAgent

public void setInsideAgent(boolean flag)
Sets the flag to indicate if the plugin container is inside an external agent or if its embedded in a managed product.

Parameters:
flag -

toString

public String toString()
Overrides:
toString in class Object
See Also:
Object.toString()

getDefaultClassLoaderFilter

public static String getDefaultClassLoaderFilter()
Returns the default filter for class loading that is used to prevent leaking of agent / PC classes to plugins.

Returns:
A regular expression to match classes against


Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.