Plugin Descriptor Metadata
Define the resource type in the plugin descriptor, specifying general information on the resource type such as name and description.
Specify the name of the class that will be used to discover resources of this type.
Specify the name of the class that will be used to connect to and provide hooks for any subsystems in use.
Add metadata to describe which subsystems the plugin will support for the resource type, such as indicating what properties may be used to configure the resource or what operations may be executed.
Implement the class that will perform discovery of resources (the name of this class is indicated in the metadata above).
Implement the class that will connect to the resource (resource component). There will be one instantiation of this class for each resource of this type that is discovered.
Implement the required interfaces on the resource component for each subsystem indicated in use by the plugin descriptor. In other words, if the plugin descriptor indicates the resource can be configured, the configuration interface must be implemented by the resource component for this resource type.
Include plugin descriptor with the correct name and location
Include compiled classes for the plugin API interfaces and any supporting classes
Optional: Include any dependency JARs and files in the correct location
Copy the plugin file to the plugins directory on the RHQ server
Get the agent to download the plugin by doing one of the following:
- restarting the agent
- execute the "plugins update" command in the agent console
- execute the agent's Update Plugins operation (only if you have the RHQ Agent imported in inventory)
Changes to the pom.xml file
- Rename the artifactId and groupId
- Change the name attribute to reflect the new plugin
- Optional: Change the description attribute to reflect the new plugin
- Optional: Select a logging framework dependency (see descriptor for more details)
- Optional: Add any dependencies the new plugin requires
Remove or rename and modify the sample resource types from the plugin descriptor
Once the references to the sample code components are removed from the plugin descriptor, those classes may be deleted