Solved

Need to add dependencies programmatically to a maven project

Posted on 2010-11-08
6
1,019 Views
Last Modified: 2013-11-23
Hi Experts
I need to add dependencies jars to a maven project programmatically at runtime. The reason I want to do that because I cannot add them all at the beginning since they can be thousands of jars and the user only picks  one or two. I googled the internet but it was not very clear since some people say Don’t do that . I really need an expert-advice

Thanks


0
Comment
Question by:bachra04
  • 3
6 Comments
 
LVL 17

Expert Comment

by:Thomas4019
ID: 34090946
Hmm, could you possibly merge the jars into a single jar or just a few?
0
 
LVL 2

Author Comment

by:bachra04
ID: 34093641
no I can't because the purpose of the solution is to have different jars that can be shared between different teams.
0
 
LVL 2

Accepted Solution

by:
bachra04 earned 0 total points
ID: 34102069
I figured out that just adding a dependency block to the POM.XML does the job. My question is now, is there any API to do that or do I have to program that myself ?

Thanks
0
 
LVL 2

Author Closing Comment

by:bachra04
ID: 34237248
I did'nt receive any good answer
0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Application launch issue with Apache Tomcat 5 42
Spring Framework HTTPSession management 1 33
fibonacci ten numbers 4 38
login jsp example 24 47
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Whether you’re a college noob or a soon-to-be pro, these tips are sure to help you in your journey to becoming a programming ninja and stand out from the crowd.
The viewer will learn how to implement Singleton Design Pattern in Java.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question