ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dierckx, Geroen" <geroen.dier...@eds.com>
Subject RE: Websphere 4.0.3: Exception while calling ejbdeploy
Date Thu, 27 Jun 2002 07:33:43 GMT
The websphere.home property should be set to your was home (in windows most
likely c:\Websphere\Appserver). If you do this it should work (for me it
does). I also pointed this out to the ant-dev mailinglist but haven't got
many answers. (http://nagoya.apache.org/bugzilla/show_bug.cgi?id=9973)



-----Original Message-----
From: McVeigh, Ryan 
Sent: Tuesday, June 25, 2002 3:44 PM
To: 'ant-user@jakarta.apache.org'
Cc: 'ant-dev@jakarta.apache.org'
Subject: Websphere 4.0.3: Exception while calling ejbdeploy
 
Hi all, 
 
I'm using Ant 1.5Beta 2.  I've got an ejbjar task in my Websphere build and
I'm seeing the following error which I believe is a "bug" or at least a
documentation omission.  I've tried to include as much detail as possible to
explain the problem.  I also apologize in advance for cc'ing the dev list,
however this email includes at least two potential bugs within Ant 1.5, so I
wanted to get the right audience.  My error is:
 
Exception while calling ejbdeploy. Details: java.lang.NullPointerException
 
I have bcel.jar in my classpath.  My JAVA_HOME is pointing to my Websphere
installed JDK (c:\websphere\appserver\java).  I believe I have properly
included the ejbdeploy tool in the wasclasspath element.
 
My websphere element looks like:
 
                                    <websphere
destdir="${dist.websphere.ejbs.dir}"
                                                codegen="true"
                                                ejbdeploy="true"
                                                keepgeneric="false"
                                                newCMP="true"
                                                quiet="false">
                                                <classpath>
                                                            <pathelement
location="${build.classes.dir}"/>
                                                            <pathelement
path="${shared.thirdparty.jars}"/>
                                                </classpath>
                                                <wasclasspath>
                                                            <pathelement
path="${shared.thirdparty.jars}"/>
                                                            <pathelement
path="${shared.websphere.jars}" />
                                                            <pathelement
location="${build.classes.dir}"/>
                                                            <pathelement
location="${websphere.jar}"/>
                                                </wasclasspath>
                                    </websphere>
 
Running with verbose, here's my output:
 
BUILD FAILED
C:\depot\ibm\appsvcs\build\build_main.xml:177: Exception while calling
ejbdeploy. Details: java.lang.NullPointerException
        at
org.apache.tools.ant.taskdefs.optional.ejb.WebsphereDeploymentTool.buildWebs
phereJar(WebsphereDeploymentTool.java)
        at
org.apache.tools.ant.taskdefs.optional.ejb.WebsphereDeploymentTool.writeJar(
WebsphereDeploymentTool.java)
        at
org.apache.tools.ant.taskdefs.optional.ejb.GenericDeploymentTool.processDesc
riptor(GenericDeploymentTool.java)
        at
org.apache.tools.ant.taskdefs.optional.ejb.EjbJar.execute(EjbJar.java)
        at org.apache.tools.ant.Task.perform(Task.java)
        at org.apache.tools.ant.Target.execute(Target.java)
        at org.apache.tools.ant.Target.performTasks(Target.java)
        at org.apache.tools.ant.Project.executeTarget(Project.java)
        at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java)
        at org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java)
        at org.apache.tools.ant.Task.perform(Task.java)
        at org.apache.tools.ant.Target.execute(Target.java)
        at org.apache.tools.ant.Target.performTasks(Target.java)
        at org.apache.tools.ant.Project.executeTarget(Project.java)
        at org.apache.tools.ant.Project.executeTargets(Project.java)
        at org.apache.tools.ant.Main.runBuild(Main.java)
        at org.apache.tools.ant.Main.start(Main.java)
        at org.apache.tools.ant.Main.main(Main.java)
--- Nested Exception ---
java.lang.NullPointerException
        at java.io.File.<init>(File.java:194)
        at
org.apache.tools.ant.taskdefs.optional.ejb.WebsphereDeploymentTool.buildWebs
phereJar(WebsphereDeploymentTool.java)
        at
org.apache.tools.ant.taskdefs.optional.ejb.WebsphereDeploymentTool.writeJar(
WebsphereDeploymentTool.java)
        at
org.apache.tools.ant.taskdefs.optional.ejb.GenericDeploymentTool.processDesc
riptor(GenericDeploymentTool.java)
        at
org.apache.tools.ant.taskdefs.optional.ejb.EjbJar.execute(EjbJar.java)
        at org.apache.tools.ant.Task.perform(Task.java)
        at org.apache.tools.ant.Target.execute(Target.java)
        at org.apache.tools.ant.Target.performTasks(Target.java)
        at org.apache.tools.ant.Project.executeTarget(Project.java)
        at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java)
        at org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java)
        at org.apache.tools.ant.Task.perform(Task.java)
        at org.apache.tools.ant.Target.execute(Target.java)
        at org.apache.tools.ant.Target.performTasks(Target.java)
        at org.apache.tools.ant.Project.executeTarget(Project.java)
        at org.apache.tools.ant.Project.executeTargets(Project.java)
        at org.apache.tools.ant.Main.runBuild(Main.java)
        at org.apache.tools.ant.Main.start(Main.java)
        at org.apache.tools.ant.Main.main(Main.java)
 
--
 
In browsing the code for the WebsphereDeploymentTool.buildWebsphereJar()
method, the only place I could readily see that a file was being used was
here:
 
                // Set the working directory
                javaTask.setDir(new
File(getTask().getProject().getProperty("websphere.home")));
 
I don't happen to have a websphere.home property created.  Is this a
requirement?  I added a websphere.home property to my build.  It didn't seem
to matter what this property was set to, just any old directory worked.  I
got a little further, but finally ended with the following "error":
 
[ejbdeploy] Starting workbench.
 
[ejbdeploy]
 
[ejbdeploy] Shutting down workbench.
 
[ejbdeploy] Error starting EJBDeploy environment:
org.eclipse.core.internal.runtime.InternalPlatform.
[ejbdeploy] java.lang.ClassNotFoundException:
org.eclipse.core.internal.runtime.InternalPlatform
[ejbdeploy]     at
org.eclipse.core.internal.boot.DelegatingURLClassLoader.loadClass(Delegating
URLClassLoader.java:644)
[ejbdeploy]     at java.lang.ClassLoader.loadClass(ClassLoader.java:445)
[ejbdeploy]     at
org.eclipse.core.internal.boot.InternalBootLoader.startup(InternalBootLoader
.java:908)
[ejbdeploy]     at
org.eclipse.core.boot.BootLoader.startup(BootLoader.java:340)
[ejbdeploy]     at
com.ibm.etools.ejbdeploy.batch.impl.BatchDeploy.startup(BatchDeploy.java:169
)
[ejbdeploy]     at
com.ibm.etools.ejbdeploy.EJBDeploy.startup(EJBDeploy.java:309)
[ejbdeploy]     at
com.ibm.etools.ejbdeploy.EJBDeploy.execute(EJBDeploy.java:65)
[ejbdeploy]     at
com.ibm.etools.ejbdeploy.EJBDeploy.main(EJBDeploy.java:248)
[ejbdeploy] Java Result: 1
   [ejbjar] deleting generic jar
C:\depot\ibm\appsvcs\dist\websphere\ejbs\vgn-appsvcs-ejbs-generic.jar
 
--
 
I say "error" because the build still continued instead of failing.  My jar
was not generated.  Strange.  This probably another bug.
 
So in summary - can someone confirm the need for the websphere.home
property?  Is that a bug?  Also, should my ejbdeploy be working?  I can
deploy with the jar that ant creates when I set the ejbdeploy property to
"false".
 
Thanks,
 
-Ryan

--
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