Maven - pom.xml - Project Object Model

1 - About

pom.xml is an XML representation of a Maven project known also as the project descriptor.

It is ultimately a project declaration. Where as a build.xml tells ant precisely what to do when it is run (procedural), a POM states its configuration (declarative).

The POM is the basic unit of work in Maven.

You can create it:

Definition of:

  • definition of dependencies: All dependencies required to build and run an application


3 - Simple POM



  • project is the top-level element in all Maven pom.xml files.
  • modelVersion indicates the version of the model
  • The coordinate of a specific project in time is represented by:
    • groupId indicates the unique identifier of the organization or group that created the project.
    • version indicates the version of the artifact generated by the project. The SNAPSHOT designator in a version that a project is in a state of development.

Description/Documentation Element:

  • name indicates the display name used for the project.
  • url indicates where the project's site can be found.
  • description provides a basic description of your project.

4 - Third party integration

4.1 - Ant

The target fetchDependencies of an ant build script looks at the required dependencies, looks at maven's dependency cache (in the user's home directory) and downloads the dependency jar files from one of the maven repositories to the shared dependency cache.

4.2 - Eclipse

To convert pom.xml to a project file for an IDE, you can use the utility mvn:

4.3 - Idea

IDEA - Maven

5 - Documentation / Reference

Data Science
Data Analysis
Data Science
Linear Algebra Mathematics

Powered by ComboStrap