Log In
Or create an account ->
Imperial Library
Home
About
News
Upload
Forum
Help
Login/SignUp
Index
Apache Maven Dependency Management
Table of Contents
Apache Maven Dependency Management
Credits
About the Author
About the Reviewer
www.PacktPub.com
Support files, eBooks, discount offers and more
Why Subscribe?
Free Access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Basic Dependency Management
Nomenclature
Reminders on Maven origins
Dependency
Long and short designations
Long designation
Short designation
Visualizing dependencies
Transitive dependencies
The concept of transitivity
Resolution
Exclusions
Optional dependencies
Parents/modules
Parent POM
Modules
Version ranges
Summary
2. Dependency Mechanism and Scopes
Scopes
Nomenclature of scope
Compile
Provided
Runtime
Test
System
Import
Scope overlay rules (via transitive dependencies)
The dependencyManagement tag
First case study
Second case study
The import scope
Modules and submodules (advanced)
Maven Reactor
Reactor sorting
Reactor options and the Reactor plugin for Maven 2
Management of dependencies in folders
The dependencies in their folders
Nonarchive files
Summary
3. Dependency Designation (advanced)
The type tag
The classic cases
Creating a new packaging/type
Case study
The first step – Maven plugin
The second step – call the plugin
The Classifier
The dependency plugin
The analyze goal
Classpath
Other goals of dependency
Other miscellaneous plugins
The Enforce plugin
The dependency convergence
Banned dependencies
Other rules
Tattletale
Dependencies
Reports
Archives
Dependency, enforce, and tattletale – conclusion
Dynamic POMs and dependencies
Effective POM and settings
Dynamic POM
Case study
A quick and dirty solution
A clean solution
With properties in command lines
Profiles and settings
Dynamic POMs – conclusion
Summary
4. Migration of Dependencies to Apache Maven
Case study
Setting the folders
Introducing Maven with standard libraries
Available POM
Unavailable POM
Disclosing information from Manifest.MF
Online tools
Checksums
Next steps
Non-Maven standard libraries
State
Quick and (very) dirty
(A bit) slower and (far) cleaner
Summary
5. Tools within Your IDE
Case study
IntelliJ IDEA
XML with XSD completion
Module Dependency Graph
Dependency addition
Dependency addition from Java code
Dependency search and generation within a POM
Conclusion on IntelliJ IDEA
Eclipse
Dependency view
Dependency Hierarchy view
Effective POM view
Maven Repository view
Conclusion on Eclipse
NetBeans
Overview
Dependency addition
Summary
6. Release and Distribute
Best practices before release
Fixing conflicts with tier-parties
Releasing the source code
The Maven Release plugin
Delivering artifacts and distributions
Artifacts
Release distribution
A simple case
Compiling both Java and Groovy sources
A complex case
Study case
Following the process
Conclusion
Distribution management
Summary
A. Useful Public Repositories
Maven Central
iBiblio
JavaNet
JBoss
CodeHaus
Apache
OSS Sonatype
Index
← Prev
Back
Next →
← Prev
Back
Next →