Modules and libraries dependencies

When developing and deploying integration applications, you may need to declare dependencies for your modules, mediation modules, and libraries. Use the dependency editor to manage these required resources.

When a new module or library is created, it does not have any dependencies. Using the dependency editor, you can add dependencies on libraries and Java™ projects. For modules and mediation modules, you can also add dependencies on J2EE projects.

For modules and mediation modules, you can add library dependencies using the dependency editor or when you are creating the module; see the related tasks "Creating a module for business services" and "Creating a mediation module" for details.

Dependency on libraries

If a module, mediation module, or library needs to use resources from another library, you have to open the module or library with the dependency editor and add a dependency on the required library. Business objects and interfaces are examples of the resources that you would want to share. For modules with dependent libraries, you would usually deploy the library with the module so that the resources are available during run time; by default, this option is selected. However, you can also choose not to deploy the library with the module (for example, because the library is already set up at the server as a globally shared utility).

Here is the CustomerQuery module opened with the dependency editor. It has a library, SharedLib, added to its library dependency list.

Module opened with the dependency editor

Libraries cannot be deployed by themselves but they can be added as dependents to a module or mediation module and be deployed with the it.

Java project dependency

Note: If you do not work with Java projects, you do not need to modify the Java project dependency.

For a module, mediation module, or library, if you add a dependency on a Java project, it is automatically added to the build path of the module or library. By default, the dependent Java class is deployed with the module and, in the case of a library, the dependent Java project is deployed when the library is deployed with a module. You can choose not to deploy the dependent Java project with the module or library. For example, if the server is separately deploying the Java project as a global utility, you can add the Java project as a dependent to your module for build purposes, and then select not to deploy it with the module.

For more information on Java projects and libraries, see the best practices topics under related references.

J2EE project dependency

Note: If you do not work with J2EE projects, you do not need to modify the J2EE project dependency.

You can also specify dependent J2EE projects for a module or mediation module. The dependency could be for build or deployment purposes or both. When a module is dependent on a J2EE project, you may want to deploy it with the module, but you may not want the J2EE project as a part of the classpath of the module because there is no real Java build path dependency on the J2EE project. In this case, you can use the dependency editor to add the J2EE project to the module for deployment. For example, if you have a human task client application for the human task service that is available from a module, you may want to add the J2EE project that has the human task client to the dependency list for the module and only select the option to deploy it with the module.

For more information on J2EE projects and Web projects, see best practices topics under related references.

Ordering

A module may have several dependencies. If there is more than one dependency, the dependencies are resolved one by one in a consistent sequence. The order in which the dependencies will be resolved is shown under Ordering. Usually, the sequence will not matter to you, but when it does, you can view the sequence and rearrange it here.

Unresolved dependencies

A module's unresolved dependencies are listed under Unresolved Projects and you will be able to select and remove them or take other appropriate actions to restore the missing projects.

Related concepts
Modules and libraries
Business integration capabilities and roles
Business integration cheat sheets
Best practices: Sharing projects
Related tasks
Creating a module for business services
Creating a mediation module
Changing default namespaces
Enabling tools capabilities
Adding dependencies to modules and libraries
Creating the library
Related reference
Best practices: Modules and packaging for business services
Best practices: Mediation modules and packaging
Business Integration perspective and views
Documentation of resources

Related information

Tutorial: Work with modules and libraries

Feedback
(C) Copyright IBM Corporation 2005, 2006. All Rights Reserved.