Upload
max-andersen
View
1.842
Download
2
Embed Size (px)
DESCRIPTION
EAP 6 comes with a Maven Repository - this means that you can now easily migrate from JBoss AS 7 to EAP 6 if your project follows goodbest practices concerning use of Maven dependencies. But it is about much more than just easy migration.The best practices we applied to the use of Enterprise Maven Repository is some that many jboss.org projects could and should consider using since it allows the projects to be easily available for productization and be easy to consume by users in tools like JBoss Tools, Forge and the many Quickstarts built around the Maven best practices.In this talk I'll present how the Maven repository came to be, what concerns we wanted to address, how you as a user utilizes this maven repository best and how jboss.org projects can benefit from its best practices too.
Citation preview
Enterprise Maven Repository...and what does it mean to you ?
Max Rydahl AndersenSenior Principal Engineer
Red Hat
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Friday 29 June 12
org == com
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Friday 29 June 12
org ~= comorg == com
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Friday 29 June 12
org ~= com org != comorg == com
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Friday 29 June 12
org ~= com org != comorg == com
Path to Product ?
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Friday 29 June 12
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Friday 29 June 12
Documentation
Getting Started
ExamplesBooks
Support
MigrationsUpgrades
Tools/IDE
Builds
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Standards/Guidelines
Trainings
Friday 29 June 12
• Pervasive Build and Dependency Management Tool
• Gives a common language to express project structure and which artifacts a project needs and which it produces
• Perfect for examples, sharing, teams, continuos integration, …
Maven
Friday 29 June 12
What is a Maven Repository
Friday 29 June 12
What is a Maven Repository
• A directory of artifacts (jar, doc, source, zip, etc.)
Friday 29 June 12
What is a Maven Repository
• A directory of artifacts (jar, doc, source, zip, etc.)
• All with a unique GAV ID
Friday 29 June 12
What is a Maven Repository
• A directory of artifacts (jar, doc, source, zip, etc.)
• All with a unique GAV ID
• Group org.richfaces.core
Friday 29 June 12
What is a Maven Repository
• A directory of artifacts (jar, doc, source, zip, etc.)
• All with a unique GAV ID
• Group org.richfaces.core
• Artifact richfaces-api.jar
Friday 29 June 12
What is a Maven Repository
• A directory of artifacts (jar, doc, source, zip, etc.)
• All with a unique GAV ID
• Group org.richfaces.core
• Artifact richfaces-api.jar
• Version 4.0.2
Friday 29 June 12
What is a Maven Repository
• A directory of artifacts (jar, doc, source, zip, etc.)
• All with a unique GAV ID
• Group org.richfaces.core
• Artifact richfaces-api.jar
• Version 4.0.2
• Metadata for dependencies between artifacts
Friday 29 June 12
How Maven Works...
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Friday 29 June 12
How Maven Works...
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Friday 29 June 12
How Maven Works...
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Friday 29 June 12
How Maven Works...Maven Central~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Friday 29 June 12
How Maven Works...Maven Central~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Friday 29 June 12
How Maven Works...Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Friday 29 June 12
How Maven Works...Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Friday 29 June 12
How Maven Works...Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Company X
Friday 29 June 12
How Maven Works...Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Company X
Friday 29 June 12
How Maven Works...Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Company X
richfaces-api.jar
Friday 29 June 12
How Maven Works...Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Company X
richfaces-api.jarrichfaces-api.jar
Friday 29 June 12
How Maven Works...Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Company X
richfaces-api.jarrichfaces-api.jar
richfaces-api.jar
Friday 29 June 12
How Maven Works...Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0</version></dependency>
pom.xml:
Company X
richfaces-api.jar
Which richfaces-api.jar ?
richfaces-api.jar
richfaces-api.jar
Friday 29 June 12
richfaces-api.jar
jsf-api.jar
Friday 29 June 12
richfaces-api.jar
jsf-api.jar
Friday 29 June 12
BOM POM!
<dependencyManagement> <dependencies> <dependency> <groupId>org.jboss.spec</groupId> <artifactId>jboss-javaee-6.0</artifactId> <version>3.0.0.Final</version> <type>pom</type> <scope>import</scope> </dependency> </dependencies></dependencyManagement>
Dependency Management: <dependencies> <dependency> <groupId>javax.enterprise</groupId> <artifactId>cdi-api</artifactId> </dependency> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.0.1</version> <scope>test</scope> </dependency> </dependencies>
Dependencies:
Friday 29 June 12
Project Wolf!• Enterprise Maven Repository
• Every jar, javadoc, source, etc. available with unique GAV
• BOM POM for stacks
• Across All JBoss Enterprise Middleware
• EAP 6/WFK 2/JDG 6
• .zip distribution
• ...and...
Friday 29 June 12
http://maven.repository.redhat.com/Friday 29 June 12
How to use ?
• Add http://maven.repository.redhat.com/techpreview/all to ~/.m2/settings.xml
• enterprise=true on archetypes/JBoss Central
• http://jboss.org/developer
Friday 29 June 12
How Enterprise Maven Repo Works
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
Friday 29 June 12
How Enterprise Maven Repo Works
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
Friday 29 June 12
How Enterprise Maven Repo Works
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
maven.repository.jboss.org
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
maven.repository.jboss.org
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
maven.repository.jboss.org
richfaces-api.jar
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
maven.repository.jboss.org
richfaces-api.jar
Which richfaces-api.jar ?
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
maven.repository.jboss.org
richfaces-api.jar
Which richfaces-api.jar ?
richfaces-api.jar
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
maven.repository.jboss.org
richfaces-api.jar
Which richfaces-api.jar ?
richfaces-api.jar
richfaces-api.jar
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
maven.repository.jboss.org
richfaces-api.jar
Which richfaces-api.jar ?
richfaces-api.jar
richfaces-api.jar
Friday 29 June 12
How Enterprise Maven Repo Works
Maven Central
JBoss.org
~/.m2/
<dependency> <groupId>org.richfaces.core</groupId> <artifactId>richfaces-core-api</artifactId> <version>4.0.0-redhat-1</version></dependency>
pom.xml:
maven.repository.jboss.org
richfaces-api.jar
Which richfaces-api.jar ?
richfaces-api.jar
richfaces-api.jar
Company X
Friday 29 June 12
Project Wolf “Rules”
1. Unique Group-Artifact-Version (GAV)
2. Community version + -redhat-<id>
• hibernate-validator-4.2.0.Final-redhat-1
• richfaces-api-4.0.0.Final-redhat-3
3. BOM POM’s for the stack(s)
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Getting in...
Friday 29 June 12
Getting in...• CDI Enable your programming model
• Transitive Closure of Dependencies in Maven Central
• Maven Archetypes
• Provide a single BOM’s for your framework
• Create Quickstarts
• Tooling
• Path to product
• OpenShift
• Mobile
Friday 29 June 12
Getting in...• CDI Enable your programming model
• Transitive Closure of Dependencies in Maven Central
• Maven Archetypes
• Provide a single BOM’s for your framework
• Create Quickstarts
• Tooling
• Path to product
• OpenShift
• Mobile
Friday 29 June 12
Getting in...• CDI Enable your programming model
• Transitive Closure of Dependencies in Maven Central
• Maven Archetypes
• Provide a single BOM’s for your framework
• Create Quickstarts
• Tooling
• Path to product
• OpenShift
• Mobile
Friday 29 June 12
What is there today ?
http://maven.repository.redhat.com
QuickStarts/Archetypes
JBoss Developer Framework
The JBoss Way
JBoss Developer Studio
Forge
Arquillian
OpenShift
Friday 29 June 12
Friday 29 June 12
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Friday 29 June 12
Documentation
Getting Started
ExamplesBooks
Support
MigrationsUpgrades
Tools/IDE
Builds
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Standards/Guidelines
Trainings
Friday 29 June 12
Documentation
Getting Started
ExamplesBooks
Support
MigrationsUpgrades
Tools/IDE
Builds
PlatformCandidateRelease
QualityAssurance
JBossEnterpriseMiddleware
Standards/Guidelines
Trainings
Friday 29 June 12
Friday 29 June 12
Friday 29 June 12
Girl-1
Friday 29 June 12
Girl-1 Girl-1-redhat-1
Friday 29 June 12
Girl-1Girl-1-redhat-1
Friday 29 June 12
Friday 29 June 12
Assasin-4
Assasin-4-redhat-3
Friday 29 June 12
Assasin-4
Assasin-4-redhat-3
Friday 29 June 12
richfaces-api.jar
jsf-api.jar
Friday 29 June 12
richfaces-api.jar
jsf-api.jar
BOM POMorg.jboss.spec.javaee6-3.0.0
Friday 29 June 12
Friday 29 June 12
Getting in...
Friday 29 June 12
Getting in...• CDI Enable your programming model
• Transitive Closure of Dependencies in Maven Central
• Maven Archetypes
• Provide a single BOM’s for your framework
• Create Quickstarts
• Tooling
• Path to product
• OpenShift
• Mobile
Friday 29 June 12
Getting in...• CDI Enable your programming model
• Transitive Closure of Dependencies in Maven Central
• Maven Archetypes
• Provide a single BOM’s for your framework
• Create Quickstarts
• Tooling
• Path to product
• OpenShift
• Mobile
Friday 29 June 12
Getting in...• CDI Enable your programming model
• Transitive Closure of Dependencies in Maven Central
• Maven Archetypes
• Provide a single BOM’s for your framework
• Create Quickstarts
• Tooling
• Path to product
• OpenShift
• Mobile
Friday 29 June 12
https://github.com/jbossas/quickstart
https://github.com/jbossas/archetypes
https://github.com/jboss-jdf/jboss-bom
Questions ?
http://jboss.org/developer
http://devstudio.jboss.com
http://maven.repository.redhat.com
Friday 29 June 12