This discussion is archived
3 Replies Latest reply: Dec 7, 2012 2:30 PM by user3671220 RSS

Include jar in the war generated by jwsc

715924 Newbie
Currently Being Moderated

How can i add jar's in the war archive generated by jwsc ?

  • 1. Re: Include jar in the war generated by jwsc
    672676 Newbie
    Currently Being Moderated
    The sub-element zipfileset in jwsc task can pack the file into target war.

    Here is a snippet:

    <jwsc ...>
    <jws ...>
    <zipfileset dir="." prefix="WEB-INF/lib">
    <include name="your.jar"/>

  • 2. Re: Include jar in the war generated by jwsc
    Kalyan Pasupuleti-Oracle Expert
    Currently Being Moderated

    Code given by the Kaven is absolutely correctly you can try that particular script it will work.

  • 3. Re: Include jar in the war generated by jwsc
    user3671220 Newbie
    Currently Being Moderated
    Weblogic 9.2 does not support zip need to add sepate task like below
    <project name="webservices-complex" default="build-service">
    <path id="dependencyfinder">
    <pathelement location="C:/bea/weblogic92/server/lib/weblogic.jar"/>


         <taskdef name="jwsc" classname="">
              <classpath refid="dependencyfinder"/>

         <target name="build-service">
              <jwsc srcdir="src"
                   destdir="." keepGenerated="true" verbose="on" debug="true"
                   listfiles="true" classpathref="dependencyfinder">
                   <pathelement path="${java.class.path}" />
                   <pathelement path="c:/CustInfo.jar" />
                   <jws file="" >
              <zip destfile="ServiceConsumer.war" update="true">
                   <zipfileset dir="src" prefix="docs/user-guide"/>
                   <zipfileset dir="build" prefix="build"/>
                   <zipfileset dir="Webcontent/WEB-INF/lib" includes="CustInfo.jar" fullpath="WEB-INF/lib/CustInfo.jar"/>


  • Correct Answers - 10 points
  • Helpful Answers - 5 points