Skip to main content
Version: 5.2.0.1

Dependency Management

Overview

Dependency management is a fundamental aspect of software engineering. Each artifact delivered to a customer must be associated with a defined version, and any subsequent fixes must be applied to the exact configuration originally delivered to the customer. To ensure this consistency, dependency management based on semantic versioning is required.

The basic principles of this approach are:

  • Whenever an artifact is released, a version number is assigned to that artifact, and the artifact itself must not change in the future.

  • For every dependency used within an artifact, a specific version has to be defined and used.

In the context of Orchestra, these principles can be defined as:

  • Every scenario has a version number.

  • Whenever scenario elements are imported from other scenarios, the exact version of the source scenario has to be defined.

On the basis of this idea, a Maven-based approach for dependency management was added to Orchestra. The dependencies of a scenario are described in a pom.xml file that holds all the relevant information. These are:

  • Artifact name, version, description, and group

  • Reference to the parent artifact (if available)

  • Dependencies to other scenarios

  • Repositories for resolving dependencies

  • Repositories for deploying artifacts

Orchestra follows the workspace approach. This means there is a root folder (the workspace) that holds all scenarios which share the same versioning life cycle. The so-called parent POM holds general information that is necessary for the individual scenarios. Whenever a new scenario is created in this workspace, the scenario is added as a module to the workspace. Furthermore, a child POM is created within the scenario directory which derives all basic settings from the parent POM.

The approach of using a parent POM is very useful. Whenever dependencies have to be managed for all elements in the same manner, the parent POM is the right place. All dependencies and their corresponding versions are defined in the parent POM. These settings are used by the child POMs. Whenever the settings in the parent POM change, these changes are automatically inherited by the child POMs. On the basis of this approach, a migration to a new version of another scenario library is easily possible—one only has to change the version of the dependencies in the parent POM.