Bamboo allows you to isolate Maven 2.x builders on an agent-specific basis. If you configure repository isolation for a particular Maven 2.x builder capability, each agent that uses this builder will have its own private Maven 2.x artifacts directory, thereby allowing you to avoid these jar and dependency file corruptions. Each isolated repository directory has the path:

$BAMBOO_HOME/.m2/AGENT-${agendid}/repository

You may want to configure repository isolation for Maven builders, if you run multiple Maven 2.x builders on one server machine which run under the same user account on that server, but belong to different Bamboo agents. In this case, the agents will use the same default Maven 2.x artifacts directory: $HOME/.m2/repository (or %USERPROFILE%\.m2\repository for Windows-based servers). This is the directory to which Maven dependency jars are downloaded and where project artifacts are installed during the "install" phase of a Maven 2.x build.

Hence, problems can arise if Bamboo uses these multiple Maven 2.x builders simultaneously. For example, if multiple agents on a single computer, each with a different Maven 2.x builder capability, start to run Maven 2.x builds simultaneously from the queue, the different Maven 2.x builders may attempt to download the same dependency to the same artifacts directory location, resulting in corruption of the downloaded jar and dependency files.

On this page:

Configuring Repository Isolation for Maven Builders

Before you begin:

To configure a new local server Maven capability with repository isolation:

  1. Click the 'Administration' link in the top navigation bar.
  2. Click the 'Server Capabilities' link in the left navigation column to display the 'Server Capabilities' page, which lists all local server capabilities currently defined in your Bamboo system.
  3. In the Add Capability section at the end of this page, choose your builder and enter its details as described:
  4. Click the 'Add' button.
  5. Click the label for the builder you have just added. The builder capability summary screen will be displayed (see 'Maven 2.x Builder' screenshot below).
  6. Click the 'Edit Capability Configuration' link. The 'Configure Capability' screen will be displayed (see 'Maven 2.x Repository Isolation' screenshot below).
  7. Select the 'Local repository isolation' check box.
  8. Click the 'Save' button.


Screenshot above: Maven 2.x Builder


Screenshot above: Maven 2.x Repository Isolation

Notes

Related Topics

Configuring a Shared Builder Capability