Home Answers Viewqa Maven including jar file in maven pom.xml

 
 


Deepak Kumar
including jar file in maven pom.xml
2 Answer(s)      2 years and 7 months ago
Posted in : Maven

Hi,

I want to include a jar file from the WEB-INF/lib folder. Please let's know how to to do this?

Thanks
View Answers

October 13, 2010 at 9:49 PM


Hi,

After doing research it found the solution for this problem.

Add the following code into your pom.xml file and the error will go away.

<p>&lt;dependency&gt;<br>
&nbsp;&nbsp; &lt;groupId&gt;json&lt;/groupId&gt;<br>
&nbsp;&nbsp; &lt;artifactId&gt;json&lt;/artifactId&gt;<br>
&nbsp;&nbsp; &lt;version&gt;2.2.2&lt;/version&gt;<br>
&nbsp;&nbsp; &lt;scope&gt;system&lt;/scope&gt;<br>
&nbsp;&nbsp; &lt;systemPath&gt;${basedir}/src/main/webapp/WEB-INF/lib/json-lib-2.2.2-jdk15.jar&lt;/systemPath&gt;<br>
&lt;/dependency&gt;<br>
</p>

Thanks



October 25, 2010 at 11:44 AM


Hi,

After doing research it found the solution for this problem.

Add the following code into your pom.xml file and the error will go away.

<dependency>
   <groupId>json</groupId>
   <artifactId>json</artifactId>
   <version>2.2.2</version>
   <scope>system</scope>
   <systemPath>${basedir}/src/main/webapp/WEB-INF/lib/json-lib-2.2.2-jdk15.jar</systemPath>
</dependency>

Thanks









Related Pages:
including jar file in maven pom.xml
including jar file in maven pom.xml   Hi, I want to include a jar file from the WEB-INF/lib folder. Please let's know how to to do this? Thanks.... Add the following code into your pom.xml file and the error will go away
pom.xml local jar
pom.xml local jar  Hi, I have placed one jar file in the WEB-INF/lib folder now I wan't to use this jar in the maven build and test phases. How to use this jar file? Thanks
pom.xml local jar
pom.xml local jar  Hi, I have placed one jar file in the WEB-INF/lib folder now I wan't to use this jar in the maven build and test phases. How to use this jar file? Thanks   HI, You can add following dependency
How to Configure pom.xml file in Maven ?
How to Configure pom.xml file in Maven ?  How to Configure pom.xml file in Maven
Maven Exclusion - Maven
was to exclude the following jar files while creating war file:jsf-api-1.2_06.jar &...Maven Exclusion  While doing a project I was encountered a problem... jsf-api-1.2_06.jar jsf-impl-1.2_06.jar Here is the full code of maven-war
Maven Jobss Plugin - Maven
application on Jboss using maven 2: Step 1: Add the following code into pom.xml... feature of Maven 2: In case you want to just copy the war file into jboss deploy... And maven will copy the war file into deploy directory of Jboss application server
Installing and Getting Hands on Maven
the packaging element is set to jar. This is how Maven knows to produce a JAR file from... file, let us shift on trying something out. Download Maven from... created for the new project, and this directory contains a file named pom.xml
Error with Maven while deploying the war file
Error with Maven while deploying the war file  Hi, I am new to maven... I created java spring hibernate project.. and i kept all .java files... war : war. for creating the war. then i deployed the war file in localhost 8080
java - Maven
java  Can u send the maven plug in and related jar files.. i have down loded the zip file,but i need plug in for this... Plse send.... regards raghavendra
Error with Maven while deploying the war file
Error with Maven while deploying the war file  Hi, I am new to maven... I created java spring hibernate project.. and i kept all .java files... this command mvn war : war. for creating the war. then i deployed the war file
generation - Maven
generation  I have 2 config files to a file "monappli.properties" and a file "log4j.xml" the problem is that I was asked to generate the JAR files and two outside the JAR! I do not know how outsourced both files Help
Apache Maven plugins
for including in the JAR. site Generate... Apache Maven plugins      ... a specific task on demand. Maven provides a plugin execution framework and all
maven subversion issue
tortoise) i read that for this i have to change in pom.xml file from this site... org.apache.maven.plugins maven-release-plugin svn+ssh://file:///E:/my-app-reposs then when...maven subversion issue   m doing work on maven and subversion i have
Local Maven Depenency
is the location of your downloaded jar file. Thanks...Local Maven Depenency  Hi, What is local maven dependency? How to manage local maven dependency? Thanks   Hi, If some library
maven subversion issue
repository. i read that for this i have to change in pom.xml file from this site http... org.apache.maven.plugins maven-release-plugin svn+ssh://file:///E:/my-app-reposs then when i m...maven subversion issue  m doing work on maven and subversion i have
Executing JAR file - Swing AWT
created the JAR file of my project with the Manifest File including my Main... Manifest.txt secl/*.class and my jar file is created. But there is a problem, when I execute this jar file at command prompt by the following command: C
jar file
jar file  steps to create jar file with example
jar file
jar file  jar file where it s used
jar file
jar file  how to create a jar file in java
JAR FILE
JAR FILE  WHAT IS JAR FILE,EXPLAIN IN DETAIL?   A JAR file... and applications. The Java Archive (JAR) file format enables to bundle multiple... link: Jar File Explanation
jar file
jar file  how to run a java file by making it a desktop icon i need complete procedur ..through cmd
Spring Security Maven Dependency
Spring Security Maven Dependency In the below section, you will learn about maven dependency of Spring Security. The pom.xml is a XML file that contains information about the project and configuration details used by Maven to build
Java JAR Files
; A JAR file is a collection of  class files and auxiliary resources associated with applets and applications. The Java Archive (JAR) file format enables to bundle multiple files into a single archive file. Typically a JAR file format
File path for jar file
File path for jar file  Hi Experts, I have created one eclipse... jar file of that application, unfortunately it is giving the error that resource not found for the template file. Also I had tried to get that path from user
Extract Jar File
Extract Jar File  How to extract jar file?   Hi Please open the command Prompt and to the jar file and write the command jar -xvf JaraFileName.jar
maven fortify plugin
maven fortify plugin  hi, I am trying to generate a fortify report using maven. I have downloaded plug-ins fortify-plugin-1.0... pom.xml file.But it is not working. Can you please help me with how to generate
jar file - Java Beginners
jar file  jar file When creating a jar file it requires a manifest... options in jar file. What is Jar File? JAR files are packaged in the zip format  What is Jar File?JAR files are packaged in the zip format making
MyEclipse - Maven
MyEclipse  How to run servlet programs in MyEclipse . Please give me the path and how to add JAR files. I am using MyEclipse 6.0 Thanks and Regards, senthilkumar.p
org.apache.commons.collections15.Transformer jar file
org.apache.commons.collections15.Transformer jar file  Dear, Please can you provide me the link for the following jar file: import org.apache.commons.collections15.Transformer; tahnks too much
Maven 2.x Extension for Eclipse
for Eclipse build path based on Maven's pom.xml Resolving Maven dependencies... repositories Wizards for creating new Maven projects, pom.xml or to enable... Maven 2.x Extension for Eclipse Maven Integration for Eclipse
jar file with html
jar file with html  I have a jar file. On double click it shows an applet page. Please tell me how to connect that applet into html or jsp page
JAR File - Swing AWT
JAR File   Is there anybody to solve my problem of not executing the JAR file? I have asked the question previously but I haven't got any answer yet. Please help me
Creating an executable jar file
Creating an executable jar file  When I try to create jar.exe through CMD, the manifest file created doesn't contain Main-Class attribute, even though it is included in text file used during creation of jar file
Jar file - Java Beginners
Jar file  Hello this is my second question and i hope atleast i will get answer i bulid a jar file of my project using netbeans but now problem is when i open that jar file in command prompt i got error exception in thread
How to create a jar file
???   The given code creates a jar file using java. import java.io.*; import...(); System.out.println("Jar File is created successfully."); } catch (Exception ex...How to create a jar file  Hello!!!! I have a project which has
Java Jar File - Java Beginners
Java Jar File  What is a Java JAR file ..and how can i open a .jar file in Java?  Just create a Jar file and Double click on it, it will automatically runs main method in that Jar : to create Project as JAR
jar filw
jar filw  how can i run window based program using jar file
What is a JAR file in Java
What is a JAR file in Java       JAR file is the compressed file format. You can store many files in a JAR file. JAR stands for the Java Archive. This file format is used
Apache HSSF Jar file location
Apache HSSF Jar file location  where can i get jar files for apache hssf
conversion of war file into executable jar file
conversion of war file into executable jar file  how to convert war file into executable jar file
struts jar file problem
struts jar file problem  hi.. I'm using struts-core-1.3.9.jar. it works well if am using ma application with internet but it shows me an error while initializing ActionServlet when i disconnected to Internet The error stack trace
quotion on .jar
quotion on .jar  in realtime where we use .jar class files.   A Jar file combines several classes into a single archive file. Basically,library classes are stored in the jar file. For more information,please go through
how to convert a jar file into .exe file
how to convert a jar file into .exe file  hi, I want convert my jar file into executable file,urgently please help me
jar File creation - Swing AWT
jar File creation  I am creating my swing applications. How can i... in java but we can create executable file in java through .jar file.. how can i convert my java file to jar file? Help me
Runnable JAR
Runnable JAR  How to create runnable JAR file in eclipse ? Please provide me step by step demo... I am windows 7 user. I have made one jar file but when I double click it,it doesn't run. Why so
Runnable JAR
Runnable JAR  How to create runnable JAR file in eclipse ? Please provide me step by step demo... I am windows 7 user. I have made one jar file but when I double click it,it doesn't run. Why so
Reading a file from Jar JAVA
Reading a file from Jar JAVA  I have added one excel sheet into a jar file. can anybody tell me how i can read that file. actually when i am running code from eclipse i able to read it but when i am adding that jar file
Reading a file from Jar JAVA
Reading a file from Jar JAVA  I have added one excel sheet into a jar file. can anybody tell me how i can read that file. actually when i am running code from eclipse i able to read it but when i am adding that jar file
Jar file creation - Swing AWT
Jar file creation  i have developed a swing application using Net... the application i gets a JAR file a lib file is also created in dist folder..this wrks fine using IDE 1.Now i want to give the application as a jar file
requesting for a jar file - Development process
requesting for a jar file  Sir Please send me a jar file of this sir , i need this package jar file org.apache.poi.hssf.usermodel for Excel reading... After extracting, put the following jar files in the lib folder of your apache

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.