Monday 15 August 2011

java - Maven: advantages of dependency management -


What are the main benefits of Maven Dependency Management? We have a Linux version on the server and every developer has to import that directory into that IDE and keep it up to date. Can Maven be simpler than that? Using per-project lib seems like a simple solution and it looks like a simple solution.

  • Do you remember where you got it from foo.jar ?
  • Are you sure that it is a legal source that no hacker tamper?
  • Which version is foo.jar okay? Is this the original version or something that you have patched up?
  • ?
  • Need foo.jar a.jar for which y.jar for which z.jar < / Code> is needed ... do you really want to download it and manage it individually?
  • You start another project. You now have the two Libs folder. Do you copy the jar or do you refer to them before the project?
  • Your second project requires a different version of a jar How do you manage it?
  • Imagine that you want to upgrade foo.jar in the next version. With Maven, this is a one-minute job. With a Lib folder, this means: searching the web, downloading a jar, putting it in the right place, possibly changing its name, removing the old version, adding a new version, making changes, cursing, similar to all dependencies Do you want to share your project with anyone else? They can not consider their versions of JARs - Maven is a simple and efficient mechanism for override dependency.
  • Eventually, your legal department will come to ask you to guarantee that your project is clear from incompatible licenses. Maven can give you all the licenses of all your dependencies.

No comments:

Post a Comment