About The Course
Maven is a powerful and flexible tool for automating the building, testing and deployment of your Java projects. With great power, however, comes great complexity. The Maven build tool is presently poorly documented, and many organisations struggle in getting their developers productive in the tool.
The Maven Quickstart course from Bytecode Training bridges the documentation gap - getting students to a productive place in a single day of training. The Quickstart course gives students an efficient and cost-effective way of replacing weeks of personal study and experimentation with a single intense day of hands-on work-centric study.
Course Details
| Title |
|
| Duration |
|
| Outcomes |
|
| Cost |
|
| More Info | Booking Info |
Approach
Bytecode focusses on a "hands on" approach to training practice. Students spend short bursts of lecture time followed by interactive lab sessions where the topics are applied to real world techniques. The Maven course works toward learning outcomes by getting the students to perform a series of graded lab exercises representing the real-world challenges they will face when using Maven on a day-to-day basis. The labs for the Maven course include:
- Installing Maven from scratch
- Building your first maven jar using archetypes
- Constructing a web application using Maven
- Working with Maven IDE support
- Building a multi-module project
- Debugging a broken POM
- Refactoring an inefficient POM
- Generating a Maven website
- Releasing artifacts from source control
- Running an inhouse Maven repo with Nexus
- Using Hudson for continuous integration
Course Outline
The course consists of eight 45 minute modules with breaks to allow students to consolidate information. A comprehensive workbook comes with the course, along with a CD of resources used in the workshops and labs.
1. Your First Maven Project
Benefits of a Build process
Why Maven?
Maven vs (Your Other Favorite Build Tool)
Convention over Configuration
Archetypes
Lab: Your First Maven project from scratch (archetypes)
Tour of the POM
Maven Co-ordinates and versions
Dependency Basics
The Maven Repositories
Configuration Essentials
IDE Support
Lab: Adding dependencies & IDE Integration
2. POMs, Lifecycles, and Dependencies
The Build Lifecycle
Maven Plugins Intro
POMs Unmasked - The SuperPOM
Lab: Working with Plugins - adding a MANIFEST
Types of Dependencies
Dependency Resolution
Working with Custom Repositories
Lab: Working with non-mavenized 3rd party jars
Handling Conficts
Exclusions
Debugging Tools: -e, -x, dependency trees
Debugging Bizarre Maven errors
Lab: Debugging a transitive
Morning Break
3. Multimodule Applications and Testing
Multi-module projects - parent POMs, the SuperPOM
Lab: Your first multimodule app
Working with tests
Using the surefire testing plugin for JUnit
Lab: Testing multimodule apps
Deployment concerns: the assembly plugin
Classifiers and other deployment tricks
Using the exec plugin
Lab: Using the assembly plugin for all-in-one jars
4. Web Applications
Bootstrapping a web archetype
Handling appserver dependencies (provided)
Using the jetty plugin
Lab: Running your first webapp from the commandline
IDE integration
Eclipse WTP
Working with Web apps and EARs
Deployment options with Cargo
Lab: IDE Webapps, and deploying to a remote Tomcat server
LUNCH
5. Maven Sites and Reporting
How sites are generated
Site-related POM entries
Reporting toolkit - Useful 3rd party plugins (cobertura, emma, findbugs)
Introduction to APT and FML
Themes and Skins
Lab: Reporting in action, developing custom pages
Deploying sites
Lab: Site deployment
6. Refactoring POMs
Standarising properties - project.version and environment properties
Applying custom Properties
Working with filters
Lab: Properties and Filters
Maven Profiles
Profile Activation
Multi-module best practices
Lab: Profile activation and "Refactor this" exercise!
Afternoon Tea
7. The Release Process
Installing an inhouse repository
Lab: Nexus installation and quickstart
Source Code Management integration
Configurating the Subversion provider
Survey of useful SCM commands
The release process - rolling a POM
Configuring the release plugin
Lab: Releasing an artifact from SVN, Using the SCM plugin for tagging and versions
8. Where to from here?
Using a continuous integration server
Lab: Hudson configuration
Survey of interesting jump points: Writing your own plugins, Migrating Ant projects, Working with non-Java code
Introducting Maven to your org: Issues and Deployment Action Plan