Using the Apama Studio Development Environment > Working with Projects > Setting up the environment before importing projects
Setting up the environment before importing projects
A project that you want to import into Apama Studio might have dependencies on any of the following:
*Environment variables
*Catalogs of blocks, bundles or functions
*String substitutions
Before you can build your project, you would need to add each dependency to Apama Studio. An alternative to adding each dependency is to define the dependencies in a file, and place the file in the $APAMA_HOME\studio\extensions folder. When Apama Studio starts it collects any files in its extensions folder and uses them to set up the Apama Studio environment. When you then import your project its dependencies will already be in place.
Format of extensions file
A file in the extensions folder must have the .ste (Studio Tuning Extension) extension and the data it contains must be in the following format:
*Define each item to be added to Apama Studio on its own line.
*The first value in each line must be the type of the item you want to add. The type must be one of the following:
*BLOCK_CATALOG
*BUNDLE_CATALOG
*FUNCTION_CATALOG
*STRING_SUBSTITUTION
*VARIABLE
*In each line, insert a semicolon between values.
*Insert # at the beginning of a line to make it a comment.
*The values you specify vary according to the specified type. Path specifications must be fully qualified; they cannot be relative. In a path specification, you can use a variable, which can be defined directly in Apama Studio or in any .ste file. You can specify the items in any order.
*For block, bundle, or function catalogs, the format is the type followed by a path. For example:
BLOCK_CATALOG ; C:\Program Files\MyCompany\MyApp\MyBlockCatalog
*For string substitutions, the substitution value cannot be edited or removed in Apama Studio. For details, See Java development user guide > Reference > Preferences > Run/Debug > String Substitutions in the Eclipse help provided with Apama Studio. The format is as follows:
STRING_SUBSTITUTION ; variable_name ; path ; description
For example:
STRING_SUBSTITUTION ; HOME ; C:\MyApp ; Install dir for my app
*For variables, the variable's value cannot be edited and the variable cannot be removed in Apama Studio. The format is as follows:
VARIABLE ; variable_name ; path
For example:
VARIABLE ; HOME ; C:\MyApp
Suppose you have a .ste file in place and you start Apama Studio. If you subsequently modify the content of that .ste file you must restart Apama Studio for the changes to take effect.
Results of using an extensions file
After you define an extensions file, place it in the $APAMA_HOME\studio\extensions folder and then start Apama Studio.
You should see the items you defined in the extensions file in the appropriate Apama Studio dialogs. For example, select Window > Preferences and then expand Apama and click Catalogs. Any catalogs you specified in the extensions file should appear in the appropriate tab. However, you cannot edit or remove any catalogs that were added to Apama Studio by means of an extensions file.
If you import a project that uses any of the items specified in the extensions file then the imported project will be valid with regard to any of these dependencies.
Copyright © 2013-2015 Software AG, Darmstadt, Germany and/or Software AG USA Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
Use, reproduction, transfer, publication or disclosure is prohibited except as specifically provided for in your License Agreement with Software AG.