1 Getting Started with Plug-in Development

This chapter contains the following sections:

1.1 About the Plug-in Creation Process

Creating a plug-in involves the following steps, all of which are covered in this book:

  1. Designing your plug-in.

  2. Developing the plug-in, which includes creating the requisite metadata files that enable the plug-in functionality.

  3. Staging the plug-in.

  4. Validating the plug-in.

  5. Packaging the plug-in as an archive (.opar) file.

  6. Importing the plug-in into Enterprise Manager Cloud Control.

  7. Deploying the plug-in to Oracle Management Service.

  8. Adding a target from your environment to initiate target monitoring. The plug-in files required by the Management Agent to monitor the target will be pushed to the Agent at this time.

  9. Testing the plug-in to verify that it is behaving as expected.

As you continue to modify your plug-in metadata, you can upload your new metadata files to Enterprise Manager without re-deploying the plug-in archive using the Metadata Registration Service. See Section 14.7, "Updating Deployed Metadata Files Using the Metadata Registration Service (MRS)" for instructions on using this service.

In addition, to keep track of each updated version of your plug-in, you should incrementally update the plug-in version as follows in the following plug-in metadata files:

1.2 About the Extensibility Development Kit (EDK)

A key component of the Enterprise Manager Cloud Control architecture is the Extensibility framework. To enable Oracle partners to extend the Enterprise Manager platform, an Extensibility Development Kit (EDK) is provided with the product.

The EDK is a collection of tools, utilities, and documentation, including:

  • Enterprise Manager Extensibility documentation: Provide general guidelines for programming Enterprise Manager plug-ins

  • Reference Implementation: Provides a reference code implementation, code snippets, and so on for various Enterprise Manager features

  • Build time tools to verify EDK conformance: A tool that you can use to validate and report any violations, with respect to Enterprise Manager Extensibility guidelines

  • Packaging Tool: A tool to package the plug-in components tool (empdk)

  • Verification Tool: A tool to validate plug-in code components and to report violations (if any).

Enterprise Manager EDK includes a command line utility called empdk. Use this utility to package or validate a plug-in archive. For information associated with the empdk commands and their options, see Section 14.3, "Validating the Plug-in".

After you download the EDK, unzip it on your local system, and change your current directory to the location where you unpacked the EDK. The EDK contains reference documentation and guides to help you with plug-in development as well as the API reference you might need to integrate while developing plug-ins.

For information about downloading the EDK, see Section 1.3, "Installing the Extensibility Development Kit (EDK)".

1.2.1 Contents of the EDK

The EDK archive contains the following directories:

  • /bin

    Contains the empdk utility, which you use to:

    • Validate the structure of your plug-in

    • Package your plug-in

    • Convert the metadata for existing (pre-Cloud Control 12) plug-ins to the new metadata formats

  • /doc

    Contains the Oracle Enterprise Manager Extensibility Programmer's Guide and Programmer's Reference, as well as the EDK API Reference documentation, including documentation on Management Views. Review overview.html for links to the documentation provided.

    You can also access the EDK API Reference documentation directly through its index page (sdk_api_ref.html).

  • /lib

    Contains internal libraries used by the EDK.

  • /oui

    Contains internal libraries used by the EDK.

  • /samples

    Contains a complete reference implementation of a plug-in, packaged as demo_hostsample.zip. The sample metadata files included should be used as examples of the files referenced throughout the EDK documentation.

    View the README packaged with the archive for instructions on building, deploying, and using the sample plug-in.

Other utilities referenced in this documentation, including EM CLI and EM CTL, are installed with Enterprise Manager and are typically deployed to the Oracle Management Service (OMS) host.

1.3 Installing the Extensibility Development Kit (EDK)

Before you begin developing plug-ins, install the Extensibility Development Kit (EDK).


Before installing the EDK, you must have the following:
  • Latest version of the EDK ZIP archive from the Self Update console. (To access the Self Update console, from the Cloud Control console, select Setup, then Extensibility, and then Self Update.)

  • Java version 1.6.0_43 or later

  • Local system running Solaris, Linux, HP-UX, AIX, or Windows with New Technology File System (NTFS)

To install the EDK:

  1. Download the EDK ZIP archive to your local system using one of the following options:

    • Enterprise Manager Cloud Control

      1. Log in to Enterprise Manager Cloud Control.

      2. From the Setup menu, select Extensibility, then select Development Kit.

        The Extensibility Development Kit (EDK) page appears.

      3. Under Installing the EDK, select Download the Extensibility Development Kit to your workstation.

      4. Save to your local system.

    • Enterprise Manager Command Line Utility (EM CLI)


      For information about setting up EM CLI, see Section, "Setting Up the EM CLI Utility".

      Open a command prompt and run the following command:

      emcli get_ext_dev_kit

      This command downloads the EDK zip archive to the same directory from where you ran the command and does not require any parameters.

  2. Set your JAVA_HOME environment variable and ensure that it is part of your PATH. For example:

    setenv JAVA_HOME /usr/local/packages/j2sdk1.6.0_43
    setenv PATH $JAVA_HOME/bin:$PATH
  3. Unpackage the downloaded EDK ZIP archive to a directory on your local system. For example:


    This command creates the following directories under the directory (release_edk_partner) where you unpackaged the EDK ZIP archive:


    For more information about the directory contents, see Section 1.2.1, "Contents of the EDK".

1.4 Designing the Plug-in

Before creating your plug-in, you must first determine what information needs to be collected to monitor and manage the target type. This involves:

  • Identifying performance and configuration metrics that should be collected.

  • Determining how often each metric should be collected. Oracle recommends that the collection frequency for any metric should not be less than once every five minutes.

  • Based on customer-specific operational practices, specifying default warnings and critical thresholds on these metrics. Whenever a threshold is crossed, Enterprise Manager generates an alert, informing administrators of potential problems.

1.5 Creating a Basic Plug-in

Ideally, begin by creating a basic monitoring plug-in that includes the basic required metadata:

Once created, you will validate and package your plug-in. See Chapter 14, "Validating, Packaging, and Deploying the Plug-in" for instructions.

As the final step, deploy your plug-in to Enterprise Manager Cloud Control and begin testing to ensure that data for the Response metric is being returned.

See Also:

The EDK provides a sample host plug-in. This contains examples of all features mentioned previously. For more information, see the README bundled with the sample plug-in.

1.6 Creating an Intermediate Plug-in

When you have created a basic plug-in, you might want to enhance the plug-in's capabilities by adding more complex functionality.

1.7 Creating an Advanced Plug-in

When you have successfully created and validated your basic or intermediate plug-in, you might want to enhance it with advanced features. Among the enhancements to consider: