0

I'm using two jar files like httpclient-4.2.3.jar and httpcore-4.2.jar but now I want to use another two files with same name but different version httpclient-4.3.4.jar and httpcore-4.3.jar. How can I use all four files in a same project?

Please help me.

Nicomedes E.
  • 1,326
  • 5
  • 18
  • 27
atul
  • 1
  • can you update your code to use the newer version? mixing various versions is a bad idea. – mariusm Sep 18 '14 at 07:30
  • actually at some places we require old version same thing i am trying to update but it is not happening so we need to merge it – atul Sep 18 '14 at 07:36
  • duplicate? http://stackoverflow.com/questions/6105124/java-classpath-classloading-multiple-versions-of-the-same-jar-project – mariusm Sep 18 '14 at 07:38
  • i need your help. i am using grails 2.3.7 – atul Sep 18 '14 at 07:41
  • I don't do grails, sorry. – mariusm Sep 18 '14 at 07:51
  • but u can help me using maven – atul Sep 18 '14 at 07:55
  • or jarjar tools how can i use it – atul Sep 18 '14 at 07:56
  • in principle you could unpack your jars, merge the files an package them into combined jar again. but this is not going to work: java files contain code with non-trivial dependencies so you are going to break the functionality (there is a reason why they are packaged separately), moreover this will not satisfy maven dependencies (it will still depend and ask for those versions and it will not know about your merged version). – mariusm Sep 18 '14 at 07:59
  • then please guide me in proper way – atul Sep 18 '14 at 08:03

0 Answers0