Presentation is loading. Please wait.

Presentation is loading. Please wait.

Using the ALM Module Michael Youngstrom. Disclaimer This is a training NOT a presentation. – Be prepared to learn and participate in lab Please ask questions.

Similar presentations


Presentation on theme: "Using the ALM Module Michael Youngstrom. Disclaimer This is a training NOT a presentation. – Be prepared to learn and participate in lab Please ask questions."— Presentation transcript:

1 Using the ALM Module Michael Youngstrom

2 Disclaimer This is a training NOT a presentation. – Be prepared to learn and participate in lab Please ask questions Prerequisites: – Maven Knowledge https://tech.lds.org/wiki/Java_Stack_Training

3 Recent Build Landscape Changes Build/Deploy Landscape has changed since 3.1 Anthill Pro replaced CruiseControl for builds Anthill “Secondary Process” use increased Many teams now use Anthill for deployment DB Migrator continues to grow – Some teams executing migrations from Anthill Test Runner created for post build test execution Many improvements in infrastructure automation Some projects deploying UI and CDN content separate from application

4 Stack 3.1 Build Problems Integrated application deploy, functional test, and db migration with maven build – Long build times – Complex builds – Build failed if deploy failed Poor Anthill “secondary process” support – Difficult to add unique post build tasks – Inconsistency between build and post build actions

5 Goals of Build Improvements Simplify build by separating build and post build processes – Once per build vs. Many per build Give post build power to the team Leverage current investment in Maven Execute build and post build tasks inside and outside of Anthill Consistent build promotions We want fully automated deployments!!!

6 Maven Lifecycles Maven uses lifecycles to orchestrate goals Phases represent steps in a lifecycle Default process-resources compile test-compile test package integration-test install deploy Clean pre-clean clean Site site site-deploy

7 Executing a Lifecycle Lifecycles are executed by calling a phase Phase identifies where in lifecycle to stop Examples: – mvn test – mvn install – mvn clean install – mvn install site clean – mvn clean compile package install clean Default process-resources compile test-compile test package integration-test install deploy Clean pre-clean clean Site site site-deploy

8 Phases in Lifecycle Phases in a lifecycle are mapped to plugin goals – Dictated by packaging type and pom config Default PhasesWar Bindings process-resources compilecompiler:compile test-compilecompiler:testCompile testsurefire:test packagewar:war integration-test installinstall:install deploydeploy:deploy Clean PhasesBindings pre-clean cleanclean:clean Site PhasesBindings sitesite:site site-deploysite:deploy

9 Example Binding in Pom Config org.apache.maven.plugins maven-enforcer-plugin 1.0.1 enforce compile

10 ALM the Lifecycle for Deployments Default Lifecycle builds and managing artifacts What might a lifecycle for application deployment look like? – Migrate database – Deploy app – Test deployed app ALM Lifecycle PhasesBindings alm-dbstack-db:migrate alm-deploystack-tcat:deploy alm-teststack-test:functional-test alm-promote Quiz: – clean install – alm-promote – clean install alm-promote

11 Packaging the ALM Module How does this help? ALM Module creates a.zip containing: – The project – All Dependencies – settings.xml file

12 How to execute a post build promotion? 1.Download alm zip file for project 2.Execute: mvn -s settings.xml alm-promote 3.Optionally add appropriate ‘-D’ parameters 4.Specify env using a maven profile (e.g. -P stage)

13 ALM Promotion Demo

14 Lab ALM Module Builds https://tech.lds.org/wiki/Using_the_ALM_Module #Lab_1

15 Executing through Anthill Pro Anthill represents an excellent engine for executing ALM Modules – Securely store build artifacts – Can securely handle passwords – Easily add parameters to a maven build – Can track state of builds – Can record and store results from multiple test runs

16 Execute ALM Promotion in Anthill Demo

17 Roles of new Build System Project Team Set Default configuration in ALM pom.xml for project – Functional Tests? – DB Migration? – Test Groups? (smoke, full, etc) Test promotion on local box Identify Anthill configurable properties – Skip Plugins? – Usernames and passwords? Identify the Environments to enable Build Team Add Project to Anthill Take configurable properties from team add them to secondary process. Enable specified environments Java Stack Team Help Customize ALM Module

18 Imagine the Possibilities! Plugins currently tested and working with alm module: – DB Migrator – Tcat Deploy – Vanilla Tomcat Deploy – Test Runner Possible future work: – Deployment of static content – CDN Deployment/Expiration – Update of WAM Policies – Marklogic Deploy – Enhance Test runner to update QA Test Cases – Putting up Out of Service Page During Deployment – Many more

19 Conclusion ALM Module provides promotion orchestration Puts more control in hands of project team Build process now separate from promotion Anthill pro is an excellent promotion engine We hope to see more fully automated promotions in the future!!!


Download ppt "Using the ALM Module Michael Youngstrom. Disclaimer This is a training NOT a presentation. – Be prepared to learn and participate in lab Please ask questions."

Similar presentations


Ads by Google