webMethods 10.2 | Application Platform User Guide | Developing with Application Platform in Designer | About Creating Application Platform Projects | Classpath Containers | Adding the Application Platform Shared Bundles Container
 
Adding the Application Platform Shared Bundles Container
The Application Platform Shared Bundles container has a collection of libraries, which you can add to the classpath of your project. You can use this container for shared bundle dependencies. Each project can define its own classpath container for the Application Platform shared bundles container. The classpath container enables you to specify the location of the shared bundles in your file system. Make sure that you keep only valid OSGi bundles in the shared bundles directory. Any non-OSGi jars that are contained in the shared bundles directory will not be included in the library entry.
* To add the Application Platform Shared Bundles container
1. In Designer, go to the Package Explorer view, right-click your project, and select Build Path.
2. Click Add Libraries....
3. In the Add Library dialog box, select Application Platform Shared Bundles, and then click Next.
4. In the Edit Variable Entry dialog box, specify the following:
In this field...
Specify...
Name
The name of the classpath variable. Keep the default value.
Default: BUILD_EXTERNAL_DIR
Note: The BUILD_EXTERNAL_DIR variable points to the folder location that contains your project’s external dependencies.
Path
The file path to the shared bundles container in your local directory. To specify the path, click Folder, navigate to the directory that contains the bundles, and click OK. All bundles in the selected directory will be added to the classpath of your project.
When you specify a path here, you can select the folder structure under that path. Make sure that the selected directories contain valid third-party or external OSGi bundles that are added to the project as library dependencies for compilation purposes. Note that the jars in the selected directories are not included within the project bundle when it is built and deployed to the configured server runtime.
The directories that you configure in this step are added in the project assetBuild.properties file in the component.dependencies.external property. This value is used by the Asset Build Environment when building assets to resolve the external dependencies used by the project. The equivalent property in the Asset Build Environment that points to the global external build directory is called build.external.dir and is configured in the master build properties file of the Asset Build Environment.
For more information about the Application Platform project configuration for Asset Build Environment, see webMethods Application Platform User’s Guide.
5. In the Edit Variable Entry dialog box, click OK.
6. Click Finish.
The bundles that are located in the selected directories relative to the BUILD_EXTERNAL_DIR folder value are listed as library dependencies for the project.
If you add, remove, or change bundles in your local directory, refresh your project and build it to ensure that the classpath of your project is updated.
Important: If you update the BUILD_EXTERNAL_DIR classpath variable to a different location on the file system, you must also update the projects that use this shared classpath container and select the correct folder(s) that contain the libraries to be added to the classpath.
About Managing Project Dependencies

Copyright © 2017-2018 | 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.
Innovation Release