Jenkins and Maven difference

Maven is building tool/environment. Jenkins is a CI (continuous integration) tool.

Maven is more like a replacement for Ant.

  1. It assists building of the project through plugins e.g build and version control, JUnit tests, etc...
  2. It manages dependencies of your project. you define how a project should be built(plugins), and what libraries are needed (dependencies) in a pom.xml file.

Jenkins as a smart job scheduler, can not assists you with tasks like version control or JUnit test, however it can indirectly assists you with all this, by making calls to the pom.xml file in your project. And Jenkins gives you the power to decide when to call the pom.xml file, based on what condition to call, and what you want to do with the outcome. and Jenkins can listen to different events, e.g svn commit, current time is midnight etc..

This is a powerful idea. For example, you can ask Jenkins to trigger a build or run through all JUnit tests whenever a new code is committed and then, if the unit tests are passed, deploy on a target machine. or schedule heavy tasks at midnight e.g unit tests.This is the basic idea of auto deployment or AKA continuous integration. CI for short if you like.


Maven is a build tool that manages dependencies and the application life cycle. It also had a plug in design that allows you to add other tasks to the standard compile/test/package/install/deploy tasks.

Jenkins is a continuous integration suite that checks your code out of a repository, builds and packages it, and dumps it out to a server so you can test it - all hands-off. It can use Maven or Ant as its build tool.

In summary, Jenkins can use Maven as its build tool for continuous integration. You can use Maven without Jenkins if you choose not to do CI.


The first paragraph of the Jenkins Maven plugin wiki page explains the interaction between Jenkins and Maven:

"Managing Jenkins jobs is not easy when there are many of them, especially if certain parameters should be identical among many jobs. "jenkins-maven-plugin" allows to generate Jenkins jobs, one "config.xml" per job, from a simple Maven POM. This way we can have all Jenkins jobs controlled in one place, reusing any amount of configuration between them."