Updating the plug-in project manifest file

When you develop a JCICS application, or package an existing application in a plug-in project, you must update the project manifest file and include a CICS-MainClass declaration.

About this task

The CICS-MainClass declaration is used to declare the classes that can be called by other CICS applications from outside the JVM server. Do not use lazy activation policies for OSGi bundles that declare a CICS main class. CICS activates the OSGi bundles as soon as they are started in the OSGi framework. You must add the declaration manually to the manifest file.

Procedure

  1. If the manifest file is not already open in the editor, right-click the project name in the Package Explorer view and click PDE Tools > Open Manifest. The manifest file opens in the manifest editor.
  2. Select the MANIFEST.MF tab. The content of the file is displayed.
  3. Add the following declaration to the manifest file: CICS-MainClass: appname.classname where:
    appname
    Is the bundle name as shown in the manifest file.
    classname
    Is the name of the class used in the application. If more than one class is used, repeat the appname.classname element, separated by a comma.

    Optional: You can use aliases in the CICS-MainClass declaration; for example, the declaration CICS-MainClass: Table_application.CreateTable;alias=table1 assigns the alias table1 to the CICS-MainClass Table_application.CreateTable. When you define the program to CICS, you use the alias name, table1, instead of the class name. An alias is useful if you have multiple versions of the same program, each with the same class name. By using aliases you can identify the different versions.

    The following screen capture shows an example manifest file for the CICS Hello examples. The example application contains two classes: HelloCICSWorld and HelloWorld, and these are declared in the manifest file in the CICS-MainClass declaration. These classes can be called by applications outside the JVM server.

    Screen capture of a manifest showing the attributes and values.

  4. When you have added all the class declarations, press Ctrl +S to save the manifest file.

Results

You can now add the plug-in project to a CICS bundle and deploy it to zFS. CICS® bundles can contain one or more plug-ins and are the unit of deployment for your application in CICS.