ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ramu Sethu" <sra...@gmail.com>
Subject Re: No class Def Error
Date Wed, 05 Sep 2007 10:16:18 GMT
Hi prashant
I did run in debug mode, verbose mode, checked the class in the jar. I
do see the jar in class path when the build in debug mode.

Actually junit task runs without any problem. Only the custom task
gives us problem

On 9/5/07, Prashant Reddy <prashant@pramati.com> wrote:
> On Wed, 2007-09-05 at 14:56 +0530, Ramu Sethu wrote:
> > hi
> >
> > We are working in EJB and we use jboss-all-clent.jar. We have custom
> > task which makes use jboss-all-cleint.jar
> >
> > When we run our custom task with the taskdef which has
> > jboss-all-client.jar in classpath, what we get is No class found error
> > . We avoided this by adding the jar in environment variable class
> > path. But i don't know why ant doesn't take the class even though we
> > added the jar in class path
> > Also our junit task test cases uses the same jar. We don't get no
> > class def when we run the junit task alone.
> >
> > Why custom task doesn't take  that from the classpath. Am i missing some thing ?
>
> May be ANT is dropping the jar you have arranged in classpath because it
> points to non-existent file location. Run ant in verbose mode (ant
> -verbose) and check if the required jars are infact set in classpath.
>
>
> >
> >
> > I have added the trace below
> >
> > [MyTask] javax.naming.NoInitialContextException: Cannot instantiate
> > class: org.jnp.interfaces.NamingContextFactory [
> > Root exception is java.lang.ClassNotFoundException:
> > org.jnp.interfaces.NamingContextFactory]
>
> Looks like org.jnp.interfaces.NamingContextFactory is not in the classpath. Is the jar
that has this class in the classpath ?
>
> HTH
> -Prashant
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>


-- 
Thank you
Ramu S

  If A is success in life, then A equals x plus y plus z. Work is x; y
is play; and z is keeping your mouth shut.
- Albert Einstein

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message