Maven Guide: Add Repository
By default, Maven will download the artifacts from the central repository. However, not all artifacts are deployed in the central repository. The Maven Browser database contains artifacts from many other public repositories. To use theses artifacts you need to either install the artifacts in your local repository or add the repository location to your POM.

Repositories may be added by editing your POM file. Open your POM and look for the repositories element. If your POM does not contain the element you can insert it anywhere you like, somewhere at the beginning is a good location.

The repositories element should contain one or more repository elements. Each element defines the location where artifacts may be downloaded from. For example, to use the JBoss repository you might add the following to your POM:





Check the Maven site for more information about repositories in your POM.

Back to the maven guide.
 

Powered by