LDSTechForumProjects

Using the ALM Module

« Back to Java Stack Training

New in Stack 3.2 is a module known as the 'ALM' module. This module is responsible for orchestrating all of the automation steps required as part of an application deployment to an environment. This training will go into the details of the features of this module, how it works, and how your team can best take advantage of it.

Prerequisites

Slide Deck

Media:ALM_Module_Training.pptx

Section 1

Get Adobe Flash player

Lab 1

Objectives

  • Create a new Stack project.
  • Execute a local ALM Promotion.
  • Change promotion properties.

Steps

  • Create a new Stack 3.2 project by following the steps in the Creating a new LDSTech Java WebApp Project Guide.
    • Choose a "Web Application"
    • Select the JDK you currently have installed
    • Check "Add a functional test module"
    • Be sure to select an "Embedded" database otherwise you will need to use the Oracle VM.
  • Import the project into your LDSTech IDE or install maven
  • Execute a typical maven build "mvn clean install"
    • Notice that no functional tests were run and no project deployed.
  • Execute an alm-promotion "mvn alm-promote"
    • To do this in the LDSTech IDE Right click on the root project->Run As->Maven build...
    • In "Goals" enter 'alm-promote'
    • Press "Run".
  • Note: you will need firefox installed for the functional tests to succeed.
  • Notice how the alm-promote phase does nothing in all of the modules except the "alm" module.
  • Disable execution of functional tests in local environment:
    • Add or change the following property to the "local" profile's properties.
<skipFTs>true</skipFTs>

Execute alm-promotion notice functional tests don't run.

For extra credit execute an 'alm-promote' using the .zip file created by the alm module.

Lab 1 Solution

Get Adobe Flash player

Section 2

Get Adobe Flash player

Lab 2

Objectives

  • Learn to add a custom Ant Script to an ALM promotion process

Steps

  • Add the following plugin to you alm/pom.xml in the build->plugins section:
<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-antrun-plugin</artifactId>
  <version>1.7</version>
  <executions>
    <execution>
      <goals><goal>run</goal></goals>
      <phase>alm-promote</phase>
      <configuration>
        <target>
      	  <echo>Build Promoted to ${environment}!</echo>
        </target>
      </configuration>
    </execution>
  </executions>
</plugin>
  • Execute an alm promotion "mvn alm-promote"
    • Note the string "Build Promoted to ${environment}!" echoed.
  • Add the following property to the "properties" element of the "local" profile.
<environment>Local</environment>
  • Execute an alm promotion and see the output "mvn alm-promote"
  • Override the "environment" property on the command line. To see how promotions can be configured on a per execution basis.
    • If executing from the LDSTech IDE add a "property" named "environment" to the build configuration.
    • If executing on the command line try:
mvn alm-promote -Denvironment=Dude

Lab 2 Solution

Get Adobe Flash player

Section 3

Get Adobe Flash player

« Back to Java Stack Training
This page was last modified on 14 February 2013, at 12:01.

Note: Content found in this wiki may not always reflect official Church information. See Terms of Use.