Creating Manifest Files for StreamBase Adapters

Creating a Manifest File

Migration Note

Prior to release 5.0, a JAR file and manifest were required in order to use a custom adapter or Java operator in StreamBase Studio. StreamBase provided the Generate StreamBase Manifest wizard, which we recommended using to avoid common mistakes in hand-crafting the manifest.

Starting with release 5.0, manifests are not needed for custom adapters and operators. However, the manifest generation functionality remains for customers to use when sharing adapters to the Global Adapter area of the StreamBase Studio Palette.

Follow these steps to create a manifest file for a StreamBase adapter to be shared in the Global Adapter palette. These steps presume you have already used the FileNewStreamBase Embedded Adapter menu to generate template files for your custom adapter.

  1. In the Package Explorer for your project, select the Java file or files that comprise your embedded adapter or adapters. (You can combine adapters into a single JAR, if desired.)

  2. Right-click the selected files and select StreamBaseCreate Global Adapter Manifest from the context menu.

  3. In the top table of the Generate StreamBase Manifest dialog, select the classes that you want to include in the manifest by checking or unchecking their entries. You can also reorder the entries by using the Up and Down buttons.

  4. Specify the destination of the generated JAR file, choosing either a Workspace or File System destination.

    Provide the path and name of the manifest file, including the .MF extension. If you do not provide an extension, Studio appends .MF to the file name.

    • For a workspace destination, use the Browse button to select a project in the Studio workspace, and enter a file name for your manifest file. Example:

      /Test/MyAdaptersManifest.MF

    • For a file system destination, specify an absolute system path, or use the Browse button to locate a path. Example:

      C:\myjavalib\MyAdaptersManifest.MF

  5. Optionally, change the setting to overwrite any existing file.

    A sample dialog at this point:

  6. When you are ready, click OK. The wizard generates your manifest file, and includes the required statements. For example:

    Manifest-Version: 1.0
    
    Name: MyInputAdapter.class
    StreamBase-Adapter: true

Using the Generated Manifest File

Use the standard Eclipse FileExport mechanism to export your adapter to a JAR file.

On the JAR Manifest Specification page of the JAR Export dialog, select Use existing manifest from workspace and browse to select the manifest file generated in the steps above.