Maven – Password Encryption

Maven supports server password encryption. Password should be always confidential and in case of Maven, it needs password to be included in the settings.xmland clear text password should be encrypted in following scenarios, Build machine (server, CI box) is shared between multiple users Users have…

Maven – Settings Reference

Maven – settings.xml file usage In maven, general settings are declared using settings.xml file which might live in two locations, In the Maven install location: ${maven.home}/conf/settings.xml In User’s home directory: ${user.home}/.m2/settings.xml The former Mavensettings.xml are also called global settings, the latter settings.xml are referred to as user settings….

Maven – Deploying Artifacts

Deploying artifacts to remote repository is our next goal in Maven process upon completing successful builds of Artifacts. Configure settings.xml for Remote Repository Connectivity Remote repository (eg., Artifactory) is both a source location for artifacts needed for a build, and a target place to deploy…

Maven – Build Profiles

Guide to Maven Build Profiles Build profiles are elements available in the POM, and are triggered using variety of ways. Profiles are created for customizing build based on requirement, environment, property file, JDK, System OS and etc,. Profiles will also minimize the use of -f option of maven…

Maven – External Dependency

How do I use external dependencies? Dependency management is a core feature of Maven. Managing dependencies for a single project is easy. Managing dependencies for multi-module projects and applications that consist of “n” number of modules is also possible. Maven helps a lot in defining,…

Maven – Filter Resources

How do I filter resource files? Our project sometimes need to fill up or filter resource files using maven during the build time. To accomplish this in Maven, put a reference to the property that will contain the value into your resource file using the syntax ${<property…

Maven – Resources

How do I add resources to Maven Project? Resources are not (usually) code. They are not compiled, but are items meant to be bundled within your project or used for various other reasons. Every Java project contains a folder named resources, different type of projects…