Welcome to Scribd. Sign in or start your free trial to enjoy unlimited e-books, audiobooks & documents.Find out more
Standard view
Full view
of .
Look up keyword or section
Like this

Table Of Contents

1. Introducing Maven
Introducing Maven
1.1. Maven Overview
1.1.1. What is Maven?
1.1.2. Maven's Origins
1.1.3. What Does Maven Provide?
1.2. Maven’s Principles
•Convention over configuration
1.2.1. Convention Over Configuration
•Standard directory layout for projects
Standard directory layout for projects
One primary output per project
Standard naming conventions
1.2.2. Reuse of Build Logic
1.2.3. Declarative Execution
Maven's project object model (POM)
Maven's build life cycle
1.2.4. Coherent Organization of Dependencies
Local Maven repository
Locating dependency artifacts
1.3. Maven's Benefits
2. Getting Started with Maven
Getting Started with Maven
2.1. Preparing to Use Maven
2.2. Creating Your First Maven Project
2.3. Compiling Application Sources
2.4. Compiling Test Sources and Running Unit Tests
2.5. Packaging and Installation to Your Local Repository
2.6. Handling Classpath Resources
2.6.1. Handling Test Classpath Resources
2.6.2. Filtering Classpath Resources
2.6.3. Preventing Filtering of Binary Resources
2.7. Using Maven Plugins
2.8. Summary
3. Creating Applications with Maven
Creating Applications with Maven
3.1. Introduction
3.2. Setting Up an Application Directory Structure
Table 3-1: Module packaging types
3.3. Using Project Inheritance
3.4. Managing Dependencies
3.5. Using Snapshots
3.6. Resolving Dependency Conflicts and Using Version Ranges
Table 3-2: Examples of version ranges
3.7. Utilizing the Build Life Cycle
3.8. Using Profiles
3.9. Deploying your Application
3.9.1. Deploying to the File System
3.10. Deploying with SSH2
3.11. Deploying with SFTP
3.11.1. Deploying with an External SSH
Table 3-3: Site descriptor
3.13. Summary
4. Building J2EE Applications
Building J2EE Applications
4.1. Introduction
4.2. Introducing the DayTrader Application
4.3. Organizing the DayTrader Directory Structure
4.4. Building an EJB Project
4.5. Building an EJB Module With Xdoclet
4.6. Deploying EJBs
4.7. Building a Web Application Project
Table 4-1: WAR plugin configuration properties
4.8. Improving Web Development Productivity
4.9. Deploying Web Applications
4.10. Building a Web Services Client Project
Table 4-2: Axis generated classes
4.11. Building an EAR Project
4.12. Deploying a J2EE Application
4.13. Testing J2EE Applications
4.14. Summary
5. Developing Custom Maven Plugins
Developing Custom Maven Plugins
5.1. Introduction
5.2. A Review of Plugin Terminology
5.3. Bootstrapping into Plugin Development
5.3.1. The Plugin Framework
Participation in the build life cycle
Table 5-1: Life-cycle bindings for jar packaging
Accessing build information
The plugin descriptor
5.3.2. Plugin Development Tools
Choose your mojo implementation language
5.3.3. A Note on the Examples in this Chapter
5.4. Developing Your First Mojo
5.4.1. BuildInfo Example: Capturing Information with a Java Mojo
Using the archetype plugin to generate a stub plugin project
The mojo
The plugin POM
Binding to the life cycle
The output
5.4.2. BuildInfo Example: Notifying Other Developers with an Ant Mojo
The Ant target
The mojo metadata file
Modifying the plugin POM for Ant mojos
Binding the notify mojo to the life cycle
5.5. Advanced Mojo Development
5.5.1. Accessing Project Dependencies
Injecting the project dependency set
Requiring dependency resolution
BuildInfo example: logging dependency versions
5.5.2. Accessing Project Sources and Resources
Adding a source directory to the build
Adding a resource to the build
Accessing the source-root list
Accessing the resource list
5.6. Summary
6. Assessing Project Health with Maven
Assessing Project Health with Maven
6.1. What Does Maven Have to do With Project Health?
6.2. Adding Reports to the Project Web site
6.3. Configuration of Reports
6.4. Separating Developer Reports From User Documentation
Table 6-1: Project Web site content types
6.5. Choosing Which Reports to Include
Table 6-2: Report highlights
6.6. Creating Reference Material
6.7. Monitoring and Improving the Health of Your Source Code
Table 6-3: Built-in Checkstyle configurations
6.8. Monitoring and Improving the Health of Your Tests
6.9. Monitoring and Improving the Health of Your Dependencies
6.10. Monitoring and Improving the Health of Your Releases
6.11. Viewing Overall Project Health
6.12. Summary
7. Team Collaboration with Maven
Team Collaboration with Maven
7.1. The Issues Facing Teams
7.2. How to Setup a Consistent Developer Environment
7.3. Creating a Shared Repository
7.4. Creating an Organization POM
7.5. Continuous Integration with Continuum
7.6. Team Dependency Management Using Snapshots
7.7. Creating a Standard Project Archetype
7.8. Cutting a Release
8.1.1. Introducing the Spring Framework
8.2. Where to Begin?
8.3. Creating POM files
8.4. Compiling
8.5. Testing
8.5.1. Compiling Tests
8.5.2. Running Tests
8.6. Other Modules
8.6.1. Avoiding Duplication
8.6.2. Referring to Test Classes from Other Modules
8.6.3. Building Java 5 Classes
8.6.4. Using Ant Tasks From Inside Maven
8.6.5. Non-redistributable Jars
8.6.6. Some Special Cases
Table A-1: The default life-cycle bindings for the jar packaging
Bindings for the maven-plugin packaging
Table A-2: A summary of the additional mojo bindings
A.1.2. The clean Life Cycle
Default life-cycle bindings
Table A-3: The clean life-cycle bindings for the jar packaging
A.1.3. The site Life Cycle
Default Life Cycle Bindings
Table A-4: The site life-cycle bindings for the jar packaging
A.2. Mojo Parameter Expressions
A.2.1. Simple Expressions
Table A-5: Primitive expressions supported by Maven's plugin parameter
A.2.2. Complex Expression Roots
Table A-6: A summary of the valid root objects for plugin parameter expressions
A.2.2. The Expression Resolution Algorithm
Plugin metadata
Plugin descriptor syntax
A.2.4. Java Mojo Metadata: Supported Javadoc Annotations
Class-level annotations
Table A-7: A summary of class-level javadoc annotations
Field-level annotations
Table A-8: Field-level annotations
A.2.5. Ant Metadata Syntax
Appendix B: Standard Conventions
B.1. Standard Directory Structure
Table B-1: Standard directory layout for maven project content
B.2. Maven’s Super POM
B.3. Maven’s Default Build Life Cycle
Table B-2: Phases in Maven's life cycle
0 of .
Results for:
No results containing your search query
P. 1
Better Builds With Maven

Better Builds With Maven

|Views: 26|Likes:
Published by yomay

More info:

Published by: yomay on Oct 03, 2010
Copyright:Attribution Non-commercial


Read on Scribd mobile: iPhone, iPad and Android.
download as PDF, TXT or read online from Scribd
See more
See less





You're Reading a Free Preview
Pages 6 to 71 are not shown in this preview.
You're Reading a Free Preview
Pages 77 to 154 are not shown in this preview.
You're Reading a Free Preview
Pages 160 to 227 are not shown in this preview.
You're Reading a Free Preview
Pages 233 to 253 are not shown in this preview.
You're Reading a Free Preview
Pages 259 to 277 are not shown in this preview.

You're Reading a Free Preview

/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->