Maven 3… so what?

Abel Muiño
senior consultant
Nilistics, Inc.
January 18th, 2011
A bel Muiño
A bel Muiño
A bel Muiño
A bel Muiño
Maven 3… so what?
IAM
Maven1
From


       to maven2
maven 1                     maven 2
original repository layout   new repository layout
  many descriptor files       pom.xml, settings.xml
  multiprojects are an       added multiprojects
     afterthought
                             embedded use is an
                                afterthought
 ad-hoc build lifecycle      defined build lifecycle
                             reworked the internals
                                     faster
   jelly script plugins           java plugins
The
      Maven3
       Upgrade
$ mvn --version
Apache Maven 3.0.1 (r1038046;
2010-11-23 11:58:32+0100)


$ mvn clean install
[INFO] --------------------------------------
[INFO] BUILD SUCCESS
[INFO] --------------------------------------
Big
some
   changes
$ mvn package -T2C
$ mvn site
Maven2 compatible   <profile>
                    	
                    	
                        <id>maven-3</id>
                        <activation>
                    	   	   <file> <exists>${basedir}</exists> </file>
                    	   </activation>
                    	   <build>
                    	   	   <pluginManagement> <plugins>
                    	   	   	    <plugin>
                    	   	   	    	   <groupId>org.apache.maven.plugins</groupId>
                    	   	   	    	   <artifactId>maven-site-plugin</artifactId>
                    	   	   	    	   <version>3.0-beta-3</version>
                    	   	   	    </plugin>
                    	   	   </plugins> </pluginManagement>
                    	   	   <plugins>
                    	   	   	    <plugin>
                    	   	   	    	   <artifactId>maven-site-plugin</artifactId>




                      {                                                                   }
                    	   	   	    	   <executions> <execution>
                    	   	   	    	   	   	   <id>attach-descriptor</id>
                    	   	   	    	   	   	   <goals> <goal>attach-descriptor</goal> </goals>
                    	   	   	    	   </execution> </executions>
                    	   	   	    </plugin>
                    	   	   </plugins>
                    	   </build>
                    </profile>
Maven2 compatible   <profile>
                    	
                    	
                        <id>maven-3</id>
                        <activation>
                    	   	   <file> <exists>${basedir}</exists> </file>
                    	   </activation>
                    	   <build>
                    	   	   <pluginManagement> <plugins>
                    	   	   	    <plugin>
                    	   	   	    	   <groupId>org.apache.maven.plugins</groupId>
                    	   	   	    	   <artifactId>maven-site-plugin</artifactId>
                    	   	   	    	   <version>3.0-beta-3</version>
                    	   	   	    </plugin>
                    	   	   </plugins> </pluginManagement>
                    	   	   <plugins>
                    	   	   	    <plugin>
                    	   	   	    	   <artifactId>maven-site-plugin</artifactId>




                      {                                                                   }
                    	   	   	    	   <executions> <execution>
                    	   	   	    	   	   	   <id>attach-descriptor</id>
                    	   	   	    	   	   	   <goals> <goal>attach-descriptor</goal> </goals>
                    	   	   	    	   </execution> </executions>
                    	   	   	    </plugin>
                    	   	   </plugins>
                    	   </build>
                    </profile>
Maven2 compatible   <profile>
                    	
                    	
                        <id>maven-3</id>
                        <activation>
                    	   	   <file> <exists>${basedir}</exists> </file>
                    	   </activation>
                    	   <build>
                    	   	   <pluginManagement> <plugins>
                    	   	   	    <plugin>
                    	   	   	    	   <groupId>org.apache.maven.plugins</groupId>
                    	   	   	    	   <artifactId>maven-site-plugin</artifactId>
                    	   	   	    	   <version>3.0-beta-3</version>
                    	   	   	    </plugin>
                    	   	   </plugins> </pluginManagement>
                    	   	   <plugins>
                    	   	   	    <plugin>
                    	   	   	    	   <artifactId>maven-site-plugin</artifactId>




                      {                                                                   }
                    	   	   	    	   <executions> <execution>
                    	   	   	    	   	   	   <id>attach-descriptor</id>
                    	   	   	    	   	   	   <goals> <goal>attach-descriptor</goal> </goals>
                    	   	   	    	   </execution> </executions>
                    	   	   	    </plugin>
                    	   	   </plugins>
                    	   </build>
                    </profile>
Maven3 only
              <build>
              	   <plugins>
              	   	   <plugin>
              	   	   	   <groupId>org.apache.maven.plugins</groupId>
              	   	   	   <artifactId>maven-site-plugin</artifactId>
              	   	   	   <version>3.0-beta-3</version>
                          <configuration>
                            <reportPlugins>

                             </reportPlugins>
                           </configuration>
              	   	    </plugin>
              	   </plugins>
              </build>
Maven3 only
              <build>
              	   <plugins>
              	   	   <plugin>
              	   	   	   <groupId>org.apache.maven.plugins</groupId>
              	   	   	   <artifactId>maven-site-plugin</artifactId>
              	   	   	   <version>3.0-beta-3</version>
                          <configuration>
                            <reportPlugins>


                                                                        section
                             </reportPlugins>
                           </configuration>
                                                       m old r eporting
              	
              	
                  	    </plugin>
                  </plugins>
              </build>
                                          Plu gins fro
Tiny




The
  Things
Guidance
    built in
I don't care if
it works on your machine
I don't care if
it works on your machine
       (We are not shipping your machine)
NO
profiles.xml
maven 1                     maven 2
original repository layout   new repository layout
  many descriptor files       pom.xml, settings.xml
  multiprojects are an       added multiprojects
     afterthought
                             embedded use is an
                                afterthought
 ad-hoc build lifecycle      defined build lifecycle
                             reworked the internals
                                     faster
   jelly script plugins           java plugins
maven 2                  maven 3
new repository layout    drops maven 1 layout
pom.xml, settings.xml      drops profiles.xml
added multiprojects        added embedder
embedded use is an        removed reporting
   afterthought
defined build lifecycle       parallel builds
reworked the internals   reworked the internals
       faster                   faster
     java plugins           same java API
Should you
use maven3?
Should you
use maven3?
Should you
use maven3?
Should you
use maven3?
Comes



What
    next?
Polyglot
 Maven
maven
shell
Compatibility notes:
 cwiki.apache.org/MAVEN/maven-3x-compatibility-notes.html

Site plugin notes:
 cwiki.apache.org/MAVEN/maven-3x-and-site-plugin.html

Polyglot Maven:
 github.com/sonatype/polyglot-maven

Maven Shell:
 github.com/sonatype/mvnsh
Thanks for your pictures!
  Great Beyond: http://www.flickr.com/photos/tonyjcase/2191160470/
  Dunechaser: http://www.flickr.com/photos/dunechaser/3385957499/
  fedfil: http://www.flickr.com/photos/fedfil/1196374459/
  eyesore9: http://www.flickr.com/photos/eyesore9/4502273643
  steveIOW: http://www.flickr.com/photos/steveiow/3875381817/
  Daniel Hoherd: http://www.flickr.com/photos/warzauwynn/2167374017/
  James Jordan: http://www.flickr.com/photos/jamesjordan/187232931/
  prettydaisies: http://www.flickr.com/photos/prettydaisies/327192177/
  Hartwig HKD http://www.flickr.com/photos/h-k-d/3629569854/
  Ernest Figueras: http://www.flickr.com/photos/ernestfigueras/5284736179/


                                             Used under CC license
consulting for agile
software development
nilistics.net

More Related Content

PDF
Build system
PDF
Jsf, facelets, spring, hibernate, maven2
PDF
How to create a skeleton of a Java console application
PDF
JSF, Facelets, Spring-JSF & Maven
DOCX
Pom
PPTX
Apache Maven basics
PDF
Releasing Projects Using Maven
PDF
Java, Eclipse, Maven & JSF tutorial
Build system
Jsf, facelets, spring, hibernate, maven2
How to create a skeleton of a Java console application
JSF, Facelets, Spring-JSF & Maven
Pom
Apache Maven basics
Releasing Projects Using Maven
Java, Eclipse, Maven & JSF tutorial

What's hot (20)

PDF
Java EE 6 - Deep Dive - Indic Threads, Pune - 2010
ODP
Java EE 6 = Less Code + More Power (Tutorial) [5th IndicThreads Conference O...
PDF
FIWARE Tech Summit - Empower Your CKAN
KEY
Tycho - good, bad or ugly ?
KEY
How to be effective with JBoss Developer Studio
PPTX
Apache Maven 2 Part 2
PDF
Vue routing tutorial getting started with vue router
PPTX
Apache Maven for AT/QC
PDF
[Spring Camp 2013] Java Configuration 없인 못살아!
PDF
Jenkinsプラグインの作り方
PDF
JavaDo#09 Spring boot入門ハンズオン
PDF
Algotitmo Moinho
PDF
Deep Dive Hands-on in Java EE 6 - Oredev 2010
PDF
Introduction maven3 and gwt2.5 rc2 - Lesson 01
PDF
ICEfaces EE - Enterprise-ready JSF Ajax Framework
PDF
Java EE 6 = Less Code + More Power
PDF
Migration from vaadin 6 to vaadin 7 devoxx france 2013
PDF
Maven, Eclipse and OSGi Working Together - Carlos Sanchez
PPTX
Hibernate
Java EE 6 - Deep Dive - Indic Threads, Pune - 2010
Java EE 6 = Less Code + More Power (Tutorial) [5th IndicThreads Conference O...
FIWARE Tech Summit - Empower Your CKAN
Tycho - good, bad or ugly ?
How to be effective with JBoss Developer Studio
Apache Maven 2 Part 2
Vue routing tutorial getting started with vue router
Apache Maven for AT/QC
[Spring Camp 2013] Java Configuration 없인 못살아!
Jenkinsプラグインの作り方
JavaDo#09 Spring boot入門ハンズオン
Algotitmo Moinho
Deep Dive Hands-on in Java EE 6 - Oredev 2010
Introduction maven3 and gwt2.5 rc2 - Lesson 01
ICEfaces EE - Enterprise-ready JSF Ajax Framework
Java EE 6 = Less Code + More Power
Migration from vaadin 6 to vaadin 7 devoxx france 2013
Maven, Eclipse and OSGi Working Together - Carlos Sanchez
Hibernate
Ad

Similar to Maven 3… so what? (20)

PDF
Introduction in Apache Maven2
PDF
Apache Maven - eXo TN presentation
PPTX
Maven
PPTX
Apache Maven
PDF
Maven 3 Overview
PDF
Lorraine JUG (1st June, 2010) - Maven
PDF
Hands On with Maven
PPTX
How maven makes your development group look like a bunch of professionals.
DOCX
Pom configuration java xml
ODP
An Introduction to Maven Part 1
PDF
Next Generation Development Infrastructure: Maven, m2eclipse, Nexus & Hudson ...
PDF
Riviera JUG (20th April, 2010) - Maven
PDF
Ant, Maven and Jenkins
PPTX
Apache maven 2 overview
PDF
Alpes Jug (29th March, 2010) - Apache Maven
PDF
Lausanne Jug (08th April, 2010) - Maven
PDF
Maven for eXo VN
PPTX
Ordina Accelerator program 2019 - Maven
PDF
Geneva Jug (30th March, 2010) - Maven
Introduction in Apache Maven2
Apache Maven - eXo TN presentation
Maven
Apache Maven
Maven 3 Overview
Lorraine JUG (1st June, 2010) - Maven
Hands On with Maven
How maven makes your development group look like a bunch of professionals.
Pom configuration java xml
An Introduction to Maven Part 1
Next Generation Development Infrastructure: Maven, m2eclipse, Nexus & Hudson ...
Riviera JUG (20th April, 2010) - Maven
Ant, Maven and Jenkins
Apache maven 2 overview
Alpes Jug (29th March, 2010) - Apache Maven
Lausanne Jug (08th April, 2010) - Maven
Maven for eXo VN
Ordina Accelerator program 2019 - Maven
Geneva Jug (30th March, 2010) - Maven
Ad

More from Abel Muíño (7)

PDF
Ahora eres coste de estructura - SCPNA 2023
PDF
Cachopo - Scalable Stateful Services - Madrid Elixir Meetup
PDF
Mad scalability: Scaling when you are not Google
PDF
Hello elixir (and otp)
PDF
We had no idea what we were doing
KEY
Diseña una empresa
PDF
Iam New And Noteworthy
Ahora eres coste de estructura - SCPNA 2023
Cachopo - Scalable Stateful Services - Madrid Elixir Meetup
Mad scalability: Scaling when you are not Google
Hello elixir (and otp)
We had no idea what we were doing
Diseña una empresa
Iam New And Noteworthy

Recently uploaded (20)

PDF
Two-dimensional Klein-Gordon and Sine-Gordon numerical solutions based on dee...
PDF
STKI Israel Market Study 2025 version august
PDF
sbt 2.0: go big (Scala Days 2025 edition)
PDF
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
PDF
CloudStack 4.21: First Look Webinar slides
PDF
Produktkatalog für HOBO Datenlogger, Wetterstationen, Sensoren, Software und ...
PDF
Hybrid horned lizard optimization algorithm-aquila optimizer for DC motor
PDF
Credit Without Borders: AI and Financial Inclusion in Bangladesh
PDF
NewMind AI Weekly Chronicles – August ’25 Week III
PPTX
Custom Battery Pack Design Considerations for Performance and Safety
PDF
A review of recent deep learning applications in wood surface defect identifi...
PPT
What is a Computer? Input Devices /output devices
PDF
TrustArc Webinar - Click, Consent, Trust: Winning the Privacy Game
PDF
Zenith AI: Advanced Artificial Intelligence
PDF
UiPath Agentic Automation session 1: RPA to Agents
PDF
A contest of sentiment analysis: k-nearest neighbor versus neural network
PDF
sustainability-14-14877-v2.pddhzftheheeeee
PPT
Geologic Time for studying geology for geologist
PDF
Consumable AI The What, Why & How for Small Teams.pdf
PPTX
The various Industrial Revolutions .pptx
Two-dimensional Klein-Gordon and Sine-Gordon numerical solutions based on dee...
STKI Israel Market Study 2025 version august
sbt 2.0: go big (Scala Days 2025 edition)
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
CloudStack 4.21: First Look Webinar slides
Produktkatalog für HOBO Datenlogger, Wetterstationen, Sensoren, Software und ...
Hybrid horned lizard optimization algorithm-aquila optimizer for DC motor
Credit Without Borders: AI and Financial Inclusion in Bangladesh
NewMind AI Weekly Chronicles – August ’25 Week III
Custom Battery Pack Design Considerations for Performance and Safety
A review of recent deep learning applications in wood surface defect identifi...
What is a Computer? Input Devices /output devices
TrustArc Webinar - Click, Consent, Trust: Winning the Privacy Game
Zenith AI: Advanced Artificial Intelligence
UiPath Agentic Automation session 1: RPA to Agents
A contest of sentiment analysis: k-nearest neighbor versus neural network
sustainability-14-14877-v2.pddhzftheheeeee
Geologic Time for studying geology for geologist
Consumable AI The What, Why & How for Small Teams.pdf
The various Industrial Revolutions .pptx

Maven 3… so what?

  • 1. Maven 3… so what? Abel Muiño senior consultant Nilistics, Inc. January 18th, 2011
  • 7. IAM
  • 8. Maven1 From to maven2
  • 9. maven 1 maven 2 original repository layout new repository layout many descriptor files pom.xml, settings.xml multiprojects are an added multiprojects afterthought embedded use is an afterthought ad-hoc build lifecycle defined build lifecycle reworked the internals faster jelly script plugins java plugins
  • 10. The Maven3 Upgrade
  • 11. $ mvn --version Apache Maven 3.0.1 (r1038046; 2010-11-23 11:58:32+0100) $ mvn clean install [INFO] -------------------------------------- [INFO] BUILD SUCCESS [INFO] --------------------------------------
  • 12. Big some changes
  • 15. Maven2 compatible <profile> <id>maven-3</id> <activation> <file> <exists>${basedir}</exists> </file> </activation> <build> <pluginManagement> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-site-plugin</artifactId> <version>3.0-beta-3</version> </plugin> </plugins> </pluginManagement> <plugins> <plugin> <artifactId>maven-site-plugin</artifactId> { } <executions> <execution> <id>attach-descriptor</id> <goals> <goal>attach-descriptor</goal> </goals> </execution> </executions> </plugin> </plugins> </build> </profile>
  • 16. Maven2 compatible <profile> <id>maven-3</id> <activation> <file> <exists>${basedir}</exists> </file> </activation> <build> <pluginManagement> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-site-plugin</artifactId> <version>3.0-beta-3</version> </plugin> </plugins> </pluginManagement> <plugins> <plugin> <artifactId>maven-site-plugin</artifactId> { } <executions> <execution> <id>attach-descriptor</id> <goals> <goal>attach-descriptor</goal> </goals> </execution> </executions> </plugin> </plugins> </build> </profile>
  • 17. Maven2 compatible <profile> <id>maven-3</id> <activation> <file> <exists>${basedir}</exists> </file> </activation> <build> <pluginManagement> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-site-plugin</artifactId> <version>3.0-beta-3</version> </plugin> </plugins> </pluginManagement> <plugins> <plugin> <artifactId>maven-site-plugin</artifactId> { } <executions> <execution> <id>attach-descriptor</id> <goals> <goal>attach-descriptor</goal> </goals> </execution> </executions> </plugin> </plugins> </build> </profile>
  • 18. Maven3 only <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-site-plugin</artifactId> <version>3.0-beta-3</version> <configuration> <reportPlugins> </reportPlugins> </configuration> </plugin> </plugins> </build>
  • 19. Maven3 only <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-site-plugin</artifactId> <version>3.0-beta-3</version> <configuration> <reportPlugins> section </reportPlugins> </configuration> m old r eporting </plugin> </plugins> </build> Plu gins fro
  • 21. Guidance built in
  • 22. I don't care if it works on your machine
  • 23. I don't care if it works on your machine (We are not shipping your machine)
  • 25. maven 1 maven 2 original repository layout new repository layout many descriptor files pom.xml, settings.xml multiprojects are an added multiprojects afterthought embedded use is an afterthought ad-hoc build lifecycle defined build lifecycle reworked the internals faster jelly script plugins java plugins
  • 26. maven 2 maven 3 new repository layout drops maven 1 layout pom.xml, settings.xml drops profiles.xml added multiprojects added embedder embedded use is an removed reporting afterthought defined build lifecycle parallel builds reworked the internals reworked the internals faster faster java plugins same java API
  • 31. Comes What next?
  • 34. Compatibility notes: cwiki.apache.org/MAVEN/maven-3x-compatibility-notes.html Site plugin notes: cwiki.apache.org/MAVEN/maven-3x-and-site-plugin.html Polyglot Maven: github.com/sonatype/polyglot-maven Maven Shell: github.com/sonatype/mvnsh
  • 35. Thanks for your pictures! Great Beyond: http://www.flickr.com/photos/tonyjcase/2191160470/ Dunechaser: http://www.flickr.com/photos/dunechaser/3385957499/ fedfil: http://www.flickr.com/photos/fedfil/1196374459/ eyesore9: http://www.flickr.com/photos/eyesore9/4502273643 steveIOW: http://www.flickr.com/photos/steveiow/3875381817/ Daniel Hoherd: http://www.flickr.com/photos/warzauwynn/2167374017/ James Jordan: http://www.flickr.com/photos/jamesjordan/187232931/ prettydaisies: http://www.flickr.com/photos/prettydaisies/327192177/ Hartwig HKD http://www.flickr.com/photos/h-k-d/3629569854/ Ernest Figueras: http://www.flickr.com/photos/ernestfigueras/5284736179/ Used under CC license
  • 36. consulting for agile software development nilistics.net

Editor's Notes