ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 9217] New: - NullPointerException in ejbjar-weblogic task with no classpath
Date Sat, 18 May 2002 02:20:58 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=9217>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=9217

NullPointerException in ejbjar-weblogic task with no classpath

           Summary: NullPointerException in ejbjar-weblogic task with no
                    classpath
           Product: Ant
           Version: 1.5Beta1
          Platform: All
        OS/Version: Other
            Status: NEW
          Severity: Minor
          Priority: Other
         Component: Optional Tasks
        AssignedTo: ant-dev@jakarta.apache.org
        ReportedBy: jcstaff@apl.jhu.edu


I downloaded the 1.5Beta1 and ran it against my build.xml files that ran 
correctly in the nightly builds as late as early April. The only noticed problem 
was a NullPointerException inside the WeblogicDeploymentTool class. 

WeblogicDeploymentTool was getting a null result back from 
GenericDeploymentTool.getCombinedPath(). GenericDeploymentTool builds this value 
from classpath which, if absent, from the task specification is null and causes 
getCombinedPath to be returned as null.

protected Path getCombinedClasspath() {
    Path combinedPath = classpath;    <-- if classpath null, this returns null
    if (config.classpath != null) {
        if (combinedPath == null) {
            combinedPath = config.classpath;
        } else {
            combinedPath.append(config.classpath);
        }
    }
    return combinedPath;
}



I added classpath="" to the weblogic attributed and the NullPointerException 
ceased. However, I got an invocation error because there was no classpath; 
causing a command like the following to be submitted "java -classpath 
-Dsomething=somthing package.Class". 

When I added classpath="xxx" to the weblogic attribute, it fixed the 
NullPointerException and the invocation error. The invocation command was then 
something like "java -classpath xxx -Dsomething=something package.Class".

<ejbjar descriptordir="${src}"
        srcdir="${classes}"
        basejarname="${ejbfile}"
        manifest="${metainf}/MANIFEST.MF"
        flatdestdir="true">
   <support dir="${classes}" includes="**/*"/>
   <weblogic destdir="${exploded.ear.dir}"
             classpath="xxx"  <--- if missing, get NullPointerException
                                   if "", get a jvm invocation error
             wlclasspath="${wl.classes}"
             newCMP="true"
             keepgeneric="false">
   </weblogic>
   <include name="META-INF/ejb-jar.xml"/>
   <dtd
   publicId="-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
   location="${dtd.dir}/ejb-jar_2_0.dtd"/>
   <dtd
   publicId="-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB//EN"
   location="${dtd.dir}/weblogic-ejb-jar.dtd"/>
</ejbjar>

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message