Build Tools Flashcards
Nexus
Maven Artifact repository administration
Maven vs Ant vs Gradle
Maven covers 70% of the buil tool marhet share for java applications; gradle 20% and ant 10%
POM
a description of the project(buil)
MAVEN Build livecycles is made up of several phases
A lifecycles is a set of predefined steps(Phases)
Each pahse is bound to one or more plugin goal
The predefined lifecycles are:
Clean - cleans the project by removing the build artifacts from the working directory
- Phase: pre-clean, clean, post-clean
- Maven Clean Plugin–> Goal: clean –> deletes everything from the target directory
Default- does the build and deployment of the project
- Validate
- Compile–> maven-compiler-plugin:compile
- Test–> maven-surfire-plugin:tesy
- Package–> maven-jar-plugin:jar
- Verify (Runs Integration Tests )
- Install (to local Maven Repo)–> maven-intstall-plugin:install
- Deploy (to share Maven Repo) –> maven-deploy-plugin:deploy
Site-creates a website for your project
Phases: Pre-site; no plugin (just a hook?)
Site–> maven-site-plugin: site
Post-site
Site-Deploy –> maven-site-plugin:deploy
MAVEN Build livecycles PHASES
is made up of several phases:
validate (checks the project structure)
compile
test
package
verify(does integration tests)
install(to local baven repo in home/.m2 folder)
deploy(to remote repo)–> this is usually handled by the CI server
**EACH PHASE WIll also run THE PREVIOUS PHASES!!!!!!
–> package generates the executable JAr(that also contains all the dependencies)
spring-boot-maven-plugin
spring-boot-maven-plugin
<executions><execution><goals>build-info<goal>
sprint-boot:run
spring-boot:build-info--> generates MANIFEST/build-info.properties
</goal></goals></execution></executions>