Creating an IBM® Workload Plug-in Project

You can use the Plug-in Development Kit to create plug-in projects.

Before you begin

You must have the Plug-in Development Kit installed and configured.

About this task

You can use virtual application patterns to add third-party software to your existing platform in an efficient, reusable way by developing the corresponding plug-in for it. Developing a plug-in for your platform requires an understanding of the conventions, configuration, and details for your platform. You typically must edit your configuration files in your preferred text editor.

The plug-in project includes the following key artifacts:
src folder
You can create your Java™ code in this directory.
JRE System Library folder
This folder contains all of the JAR files that are needed to compile the plug-in project.
i18n folder
This folder contains the globalization files.
META-INF folder
This folder contains metadata files.
OSGI-INF folder
This folder contains OSGi configuration files.
plugin folder
This folder is the plug-in configuration directory, which includes the config.json plug-in configuration file, and the following folders:
  • appmodel
  • nodeparts
  • parts
  • templates
build.plugin.xml
This Ant build file is needed to build the plug-in project.

You can add content to these artifacts to develop your plug-in.

Procedure

  1. Open the Workload Plug-in Development perspective by clicking Window > Open Perspective > Other > Workload Plug-in Development. Then, click OK.

    The Plug-in Development Kit welcome page opens.

  2. Click the Create an IBM Workload Plug-in Project link on the welcome page. You can also create a plug-in project by clicking File > New > Project > IBM Workload Plug-in Project.
  3. Enter the information for the project:
    Project name
    Set the name for your project.
    Location
    Set the location where the files for your project are stored.
    Plug-in name
    Set the name of the plug-in that is generated by your project.
    Generate project skeleton
    This setting is enabled by default. With this option checked, the wizard creates a number of files and folders automatically, which are needed by most plug-in projects. After these skeleton artifacts are created, you edit them as needed for your project. If you do not select this option, the wizard creates an empty project that includes only the config.json file. You must add other files manually as needed.
    Add project to working sets
    Use this option to add the project to a specified working set. This option is disabled by default.
  4. Click Next.
  5. Select the pattern type that the plug-in is associated with. You can choose an existing pattern type that exists in your workspace, or set a new pattern type.
  6. Click Finish.

    The Plug-in Development Kit creates the plug-in project. If you chose to create a new pattern type for the plug-in to be associated with, that pattern type is created.

What to do next

Add content to the project artifacts to develop your plug-in:
  • The plug-in configuration, in the config.json file.
  • Components, links, and policies for the Pattern Builder in the metadata.json component property UI configuration file.
  • Operations available on the Instance Console, in the operation.json configuration file.
  • Configuration parameters in the tweak.json file that can be changed on the running deployment.
  • You can create other typical plug-in artifacts, including OSGi service components, plug-in node parts, plug-in parts, and plug-in roles.