You are on page 1of 7

High-level Architecture

ESB Console Technical Information Bin

Plugin Development
Over View
The core values of the ESB console is it pluggable architecture and the plug-ins. The
pluggable architecture provide various integration points for the plug-ins. Plug-ins
are configured at each integration point and then played when users access the
integration point from the console.

ESB console allow multi level integration point for plug-ins. Integration points are hooks that
ESB console provides to manage and monitoring each component in runtimes. These hooks are
provided at various places and at multiple levels. For easy of use these integration points are
categorized into 4
1. Tree node level - Plug and play when users access the tree node

2. Tab set level - Display the group when users access the nodes/ tabs
3. Tab level - Plug and play when users access the tabs
4. Inner tab level - Plug and play when users access the inner tabs
Plug-ins

The plug-ins can be any of the following types


1. Internal Plug-in (internal registry based)
2. External Plug-in (URL base)

All the core modules of ESB console are developed as internal plug-ins. Currently it requires few
additional steps in order to develop and configure the internal plug-in compared to external plugin. Before going in detail of internal plug-ins, lets quickly see how the external plug-ins can
be developed and use the integration points to plug n play in ESB console
External Plug-ins (URL based)
As mentioned external plug-ins are URL based. What it means? An External plug-in
can be any URL based (Web) application that serves an URL entry point. This makes
ESB console technology independence. The application can be develop using any
technology as far as they serve an URL entry point they are pluggable into ESB
console.

Communication: ESB Console communicates with the external plug-ins by passing the context
values as parameters to the plug-in module entry point URL. The external plug-ins can read the
context values by querying the parameters form the URL
Module Entry Point URL?name=sun-bpel-engine&entityType=serviceengine&connectionKey=localhost_4848_true_admin&host=localhost&port=848
&targetName=domain&packagedIn=null&deployedOn=null
Name: Component name
Entity Type: Type of the component
connectionKey: Server connection key, This key used to get the server
connection info from the connection service of console.
host: Runtime Server Name
port: Runtime admin port
targetName: instance name/ cluster name/ domain if it is parent
packagedIn: Service assembly where the service unit is packaged in and null
if the component is not service unit
deployedOn: Component where the service unit is deployed on and null if the
component is not service unit

Internal Plug-in
Internal plug-ins are GWT (Google Web Toolkit) modules. ESB console is an AJAX
application built using GWT API. ESB console exposes interfaces and built in widget
library of the internal plug-in developers. All the internal GWT modules should be of
type org.glassfish.openesb.console.ui.client.external.Pluggable i.e they should
implement the Pluggable interface and provide implementation for all life cycle
methods.
void init(Component component) Initialize your plug-in module
__Note__: Call initialize (<your module root widget>) at the end of init.
Pluggable getNewInstance() return new instance of your plug-in module
void onLoad() this is called when the user access the integration point
to play the plug-in module on the console

Register your internal plug-in module in the console internal plug-ins registry as follows
1. Open org.glassfish.openesb.console.ui.client.internal.core.UIRegistry.java file
2. Add registry entry in void RegisterCore() method as follows
registeredWidgets.put("uri://<Entry Name, this should be unique from other
core registry entries. > ", new YourInternalPluginModule());

Note: This requires rebuild and deployment of ESB console. Currently we are working on the
dynamic linking of internal module, so this approach might change as we proceed on the
dynamic linking. Keep tuned to ESB console development mailing list.
Communication: Incase of internal plug-ins the context values as part of component object to
the init method. The all context parameter mentioned for the external plug-ins are part of the
component object.
When you have you plug-in module ready the nest step is to configure your plug-in.
Configure Plug-in

Plug-ins are configured in an XML configuration file. All the core plug-ins of the console are
configured in an internal configuration file called defaultnodes.xml. These configurations can be
done in an XML file manually or by using the ESB consoles rich plug-ins configuration
editor. The configuration editor not only simplifies configuration tasks but also allows applying
configurations to the console on the fly. A simple configuration file looks as follows.
<esb-console-plugin
name='BPEL Plugin'
targetComponentName='sun-bpel-engine'
version='1.0'
xmlns='http://java.sun.com/xml/ns/esb/console/PluginData'>
<pluginType

customPluginType='Management'
entityType='service-engine'
uiIntegrationType='tree-node'>
<parentId entityType='ServiceEngines'>
Service Engines
</parentId>
<displayName>
sun-bpel-engine
</displayName>
<urlEntryPoint isRelativeToContextRoot='false'>
<Your module entry point URL goes here>
</urlEntryPoint>
<imageUrl>
<Your module image icon URL goes here>
</imageUrl>
</pluginType>
</esb-console-plugin>

One plug-in configuration file define configurations for one target component i.e. one
configuration file for each target component. The root node of the configuration file defines the
context of the plug-in types defined in the file.
<esb-console-plugin
name='BPEL Plugin'
targetComponentName='sun-bpel-engine'
version='1.0'
xmlns='http://java.sun.com/xml/ns/esb/console/PluginData'>

name: Logical name to the configuration file.


targetComponentName: Component name, to which the configurations to be applied
version: Version of the configuration file
Define pluginType entry for each plug-in. The attributes of the pluginType represents the
appropriate integration point on the console i.e. in the above example
entityType represents the type of the component to which you want to plug your module to.
uiIntegrationType represents the place holder of the integration point on console.
parentId is applicable for only plug-ins with uiIntegrationType=tree-node, which
means that this plug-in is a node of the component tree on the console explorer. In which case the
parent ID is required and represents the parent node on the tree under which you want to display
your plug-in.
displayName is the name of the plug-in and is the name of the integration point to display on the
console.

urlEntryPoint represents the plug-in location. In case of external plug-in this contains fully
qualified URL of the plug-in module and in case of internal it contains the URI:// followed by
full class name. The attribute isRelativeToContextRoot is used in case of external plug-in
configuration, if it is true that mean the URL is relative and the plug-in module is deployed on
the same server as ESB console and false means the URL is a fully qualified URL and the
module is remote to ESB console.
imageURL is the display icon/image of the plug-in on the console. It can be either local (relative
URL) or remote (fully qualified URL).
For more plug-in samples go to http://wiki.open-esb.java.net/Wiki.jsp?
page=ESBConsolePluginType
After you configure your plug-ins the next step is load your plug-in configurations to the
console.
Load Plug-in configurations

Plug-in configurations are loaded using any of the following


1. Plug-in Manager (UI)
2. Deploy plug-in utility
3. Plug-in Editor
4. Command line tool

Plug-in Manager: Plug-in manager allows you to

upload the plug-in configuration files,

view the uploaded configuration files

remove, activate or deactivate the configurations files and control versions

Access plug-in manager from the welcome (Common tasks) screen

Use the plug-in manager to manage plug-ins

Deploy plug-in utility (Under development): This utility allows you to

Deploy the plug-in (war distribution) module through ESB console

Pick the plug-in configuration file from the distribution and load it through
plug-in manager

Plug-in Editor (Under development): Plug-in Editor is rich configuration editor.

It simplifies the creation and modification of plug-in- configurations using rich


editing and drag n drop features of the editor

It provides Graphical view to plug-in configuration

It allows to Import, export and merge plug-in configurations to and from a file.

Command line tool (Under development): Use command line tool to

Upload plug-in configurations

Import and export plug-in configuration

Remove plug-in configuration

You might also like