The administration of Evident ClearStone Live is performed thru the ECSL Administration Console. This is an Adobe Flex-based web application that is used to configure certain features of the ECSL Server. It can be used to configure the following system parameters:
The ECSL Administration Console is accessible from the main web page of the ECSL product.
ECSL supports role-based user administration and access control configuration. The User Administration tool allows administrators to manage user accounts and roles in the system. At minimal, each user requires a username, password, name, and email address. Access to the system features and data is managed by defining roles for both users and the data. All of the access control data is retained within ECSL's internal LDAP server.
The following screenshot illustrates the User Administration tool where ECSL Administrator can add/update user accounts and roles in the system:
ECSL enables administrators to set notification policies produced by the system. For example, when threshold violations occur, ECSL will generate events for notification. These events can be delivered via email, SNMP traps, or thru a custom event handler that is provided by the customer. In order to inform users when these events occurs, the administrator will need to configure the desired notification settings and notification policies. These settings are configured using the Admin Console under the Policies configuration.
About The Plugin User Interface
You will find the Plugin user interface by first launching the Evident ClearStone Live Administrative (ECSL) Console. Once you've successfully logged in to the console, drop down the Policies menu from the navigation pane and then select the Event Handler Plugins menu item. The user interface is shown below (as it appears upon first usage):

Connecting to the Plugin Server
Before you can perform any other activities related to Plugin management and control, you must connect to the Plugin Server. In single host solution deployments, the Plugin Server runs on the same (server) host as all the server-based services. In a more complex distributed deployment model, you'll need to know the name of the host that runs the Plugin Server. The Plugin Server runs co-resident with the Pipeline Server, so you'll need to provide that host name if you've performed a distributed host installation of ECSL.
Simply enter the hostname and press Connect. ECSL validates the Plugin Server connection. If the connection fails for any reason, a notification dialog indicating the problem will be presented.
Preparing a Plugin For Installation
The Sample Plugin
ECSL ships with an included pre-packaged sample Plugin that you can experiment with. This Plugin is quite simple but illustrative. The Plugin is available both in ready-to-deploy form and as a source project. The latter is distributed in a ZIP archive that can be directly imported via the Eclipse IDE (for Plugin developers). This Plugin can be characterized by the following features:
- Single event handler (com.evidentsoft.plugin.sample.EventHandler)
- Three (3) event channels
- allEvents - triggered for any event including those applicable to other event channels
- minorLowViolationClusterStorageMemoryFree - triggered when a minor low threshold monitoring cluster storage free memory has been violated
- criticalLowViolationClusterStorageMemoryFree - triggered when a critical low threshold monitoring cluster storage free memory has been violated
- Simple response - all 3 callbacks merely output the channel identity and received event to the standard out stream
You may freely use the sample Plugin for validation in your environment and, more importantly, as a springboard to start your own Plugin development efforts.
Obtaining the Sample Plugin
The plugin sample is distributed with ECSL as a self-extracting JAR archive; it is located in <ECSL-installation-directory>/add-ons/plugin-sample.jar. This archive contains a pre-built, read-to-deploy sample plugin, documentation and a ZIP archive containing an Eclipse-ready development project that contains the source code, tools, resources required to build the sample plugin. This development project provides a springboard for you own custom plugin development work.
To run the self-extracting archive, you will need to have made previous arrangements so that Java 6 JRE is accessible (i.e. the bin directory is in your PATH and JAVA_HOME has been established in your environment). The exact details of the extract vary slightly by platform but generally you will want to be running the platform's supported command environment (e.g. a CMD window on MS Windows platforms, BSH on Linux etc.). To extract the sample just run the following command:
java -jar <ECSL-installation-directory>/add-ons/plugin-sample.jar
The extraction process should indicate the target directory where the extraction takes place, typically this is the directory called ecsl-plugin-sample/ which is created as a subdirectory of the current user's HOME directory (e.g. on Windows this might be c:\Documents and Settings\don\ecsl-plugin-sample). The extracted sample should contain documentation (docs/), a deployable sample Plugin (/lib) and an Eclipse-ready project (plugin-project.zip). If your platform and JRE supports the desktop facility, then the extractor will launch a browser to display the content of the Evident ClearStone Plugin Developer’s Guide.
Plugin Resources Location
Plugins are generally installed from the Plugin Auto-Deployment Directory or a sub-directory. This provides containment for all deployed plugins, insures that plugins are started when ECSL starts and facilitates the deployment interface provided by the console. Generally speaking it is a good idea to create an immediate subdirectory for each plugin though this is not strictly required. It does, however, avoid collision and confusion among the set of dependent jars that plugins may employ. The auto-deployment directory is typically found here:
<ECSL-root>/config/plugins
If the Plugin Auto-Deployment Directory does not exist, you may need to create it as specified above. Create a sub-directory of the Plugin Auto-Deployment Directory called sample/. Copy the ecsl-event-plugin.jar and the log4j-1.2.15.jar to the sample/ subdirectory. From the console UI, choose the Install New Plugin tab. The set of available plugins should be shown. The sample plugin jar (ecsl-event-plugin.jar) should be present. If not, insure that the log4j-1.2.15.jar is also present in the same directory as it is required for the scan to recognize the ecsl-event-plugin.jar is a viable candidate plugin. If all proceeds accordingly, the screen should now look like this:

Notice that the lugin jar (ecsl-event-plugin.jar) appears in the list of candidate plugin jars. (We refer to a Plugin jar as a candidate until it is successfully installed.)
Installing a Plugin
Before we install the (sample) Plugin, recall that we'd located the jar(s) that the Plugin requires in a special auto-deployment directory. Besides becoming an available candidate that is visible (in the UI) for installation, ECSL regards any Plugins that have been located here as candidates for un-attended start. This means that ECSL will automatically install and start all plugins that are found in the auto deployment directory or in any sub-directory. This auto-deployment step occurs only at ECSL startup. Since we've just located the sample Plugin here, it won't automatically install until we explicitly request that it do so (or we restart ECSL).
We'll prepare to install the sample Plugin by first selecting it from the list of available jars and then by giving it a Plugin ID of sample. Once that's done we merely need to press the Install button to begin the Plugin installation process. If installation proceeds successfully, the Plugin will be listed in the Plugins table. The entry identifies the Plugin by its ID, indicates the (primary) Plugin jar and the Plugin state. Plugins that install properly undergo several state transitions. After installation the Plugin remains in the loaded state until the Plugin framework prepares the internal "machinery" required for event dispatch (delivery). Once this has been established the Plugin transitions to the running state. Shown below is an example of what the user interface might show. Note: we've selected the Plugin from the Plugins list and have selected the Plugin Details tab to observe the information available. We'll say more about this in a moment.

Note: Plugins are given a Plugin ID that must be unique among all known Plugins. This user-provided moniker is merely a distinguishing reference to the instance of the Plugin and is otherwise not important to the Plugin framework. Since there is no restriction on installing the same Plugin more than once, its distinct identity allows us to readily differentiate all Plugin instances including those representing the same underlying Plugin (code).
Viewing the Plugin Details
Plugin details are shown by first selecting the Plugin you wish to work with from the plugins table, then by selecting the Plugin Details tab. To update the details statistics while looking at this tab, merely press the Refresh Stats button as desired. The figure below shows the state of our Plugin after it has had an opportunity to run a bit and to process some events.

Information that is common to all plugins is shown on the left hand side of the details view. This includes the plugin's ID, a count of the events delivered, the time of receipt of the most recent event and the average time spent in the plugin code that is specific to the handling of each event. (The average handler time benchmark is a measure of the plugin's efficiency in handling events.) A fraction shows the greatest number of events that were simultaneously waiting to be processed (2 in our example) and the greatest number that can be waiting (64) before events are lost. The event lost count, if any, is also presented.
A Plugin may be designed and implemented such that it handles more than one distinct class of event. In Plugin parlance this is known as a channel. Each event channel is associated with a name and a filter expression that isolates the events of interest to the channel. The Plugin implementation provides one (or more) callbacks for each channel so that custom Plugin code may be executed in response to a channel event. On the right hand side of our details view, the table shown provides information about each channel and the distribution of channel-matching events that may have been received. For example, the minorLowViolationClusterStorageMemoryFree channel has triggered the Plugin callback for this channel a total of 4 times.
Note: It's important to note that channel definitions may overlap. This is illustrated here by the allEvents channel which is active for every event. The Events Delivered count is equal to the total events delivered to Plugin callbacks across all channels but does not necessarily represent the number of unique events received by the Plugin. In our sample Plugin , the allEvents channel identifies the number of distinct unique events, seven (7) of these were violations and 11 were others. Your plugin may not include an "all events" channel, so be careful about drawing conclusions from these statistics.
If you want to purge the collected statistics and restart from scratch, just select the Plugin of interest from the Plugins table and press the Reset Stats button. This will "zero" all statistics.
Pausing and Resuming
Plugin operations, i.e. receipt and handling of events for any defined channel, may be temporarily interrupted as desired. To do so, select the Plugin from the Plugins table and, if its state is currently running, press the Pause button. The Plugin state should show stopped and the Pause button is replaced with a Restart button that can be used to resume event handling in the selected (stopped) Plugin. See below:
Put images/ui-stopped-plugin.png
Notice that, while stopped, the Plugin buffers a limited number of events. Here, we've buffered up to 8 events that are pending delivery. A restarted Plugin will receive all pending events immediately after resumption. In the event that the dispatch queue reaches its limit while a Plugin is paused, some events may be lost. These are indicated by the events lost count. The queue keeps the newest events when it reaches full capacity. The oldest occurring events are lost.
Un-Installing a Plugin
A Plugin may be un-installed at any point in its lifecycle merely by selecting it from the Plugins list and then by pressing the Uninstall button. After being uninstalled the Plugin is no longer shown in the Plugins list and all details are lost.
Note: ECSL makes no guarantee that the Plugin will not be interrupted during the handling of an event or that any pending events will be processed. It's important to note that had the Plugin been installed from the auto deployment directory as described, the Plugin will still be restarted upon ECSL restart. To avoid this condition, you'll need to remove the Plugin jar (and any additional jar resources) from the auto deployment directory (or subdirectory). Following un-installation, the jar resources may be briefly held by ECSL (until garbage collection). If you have trouble removing these jars, simply wait a bit and try again.
Autonomous Behavior
ECSL supports autonomous Plugin installation and startup for any Plugins located in the auto deployment directory (or a subdirectory) as we've previously described. Furthermore, ECSL maintains a Plugins Registry that is part of its persistent configuration that identifies all Plugins that are known to have been installed either explicitly (using the user interface) or via the auto deployment mechanism. Plugins that are incorporated to this registry are candidates for autonomous behavior even if their resources are not located in the auto deployment directory.
If you wish to remove all Plugins from consideration, you need to (a) remove any Plugins from the auto deployment directory (or subdirectory) and (b) remove the Plugins registry. The registry is stored in an XML configuration file that is typically found here:
<ECSL-installation- directory>/config/perco/perco$description=Clearstone%20Plugin%20Extensions%20Registry,instance=global,name=plugins,scope=global
(Note: %20 represents the SPACE character.)
Managing Plugins
Plugins may be explicitly managed (i.e. installed, un-installed, started, stopped, monitored) using the console as we've previously shown. You must make arrangements to deliver the Plugin jar(s) to the target host system (ECSL Plugin Server). Future versions of ECSL will likely support a Plugin upload capability.
Auto Deployment
We've already briefly discussed the Plugin auto deployment capability. The Plugin auto-deployment directory is controlled by a property of the Lodestar configuration (found in <ECSL-installation-directory>/tomcat/webapps/lodestar/conf/lodestar.properties). The relevant configuration options are shown below:
# PLUGIN-CONTROL
plugins.enabled = true
plugins.autodeploy.dir = ${evident.root}/config/plugins
The default directory, controlled by plugins.autodeploy.dir, is shown. In the event that you change this directory, an ECSL restart is required. Furthermore, you must keep in mind that the deployment registry maintained by ECSL may reference Plugins that were previously deployed to an old auto-deployment directory (or sub-directory). To insure that this is not the case, you should remove the Plugins registry (found here:
<ECSL-installation-directory>/config/perco/perco$description=Clearstone%20Plugin%20Extensions%20Registry,instance=global,name=plugins,scope=global)
The Plugins registry, furthermore, may reference Plugins that are outside the scope of the auto-deployment directory. In general it is recommended that you first copy Plugins (and their dependencies) to the auto-deployment directory (or sub-directory) before deployment. Doing so avoids referencing Plugins that may be orphaned if the Plugins registry is deleted.
Enabling / Disabling
The plugins.enabled parameter represents a master control or "kill switch" for Plugin control. Setting this to false (and restarting ECSL if running) defeats the deployment of all Plugins but does not otherwise affect the auto-deployment directory contents or the contents of the Plugins registry.
References and Other Resources
For a great deal more information about Plugins and, specifically, Plugin development, please see:
Evident ClearStone Live - Plugin Developer's Guide
