ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vincent Massol" <vmas...@octo.com>
Subject RE: Problem Logging in Tasks
Date Wed, 27 Feb 2002 18:31:17 GMT
Err ... hum ... how shall I say ? .... errr .... well, it was entirely
my fault !

Well, I guess it's been several years I'm having this kind of "bug" and
I'm still not able to detect it quickly. 

I was modifying a version of my source and there was another compiled
version in the classpath ...

Sorry about the spam.
Thanks
-Vincent

> -----Original Message-----
> From: Vincent Massol [mailto:vmassol@octo.com]
> Sent: 26 February 2002 22:02
> To: 'Ant Developers List'
> Subject: RE: Problem Logging in Tasks
> 
> Another item that may be of importance : my build.xml is actually
> calling another build.xml. Could it be that the log doesn't make it
> through to the first build and thus is not printed on stdout ?
> 
> Thanks
> -Vincent
> 
> > -----Original Message-----
> > From: Vincent Massol [mailto:vmassol@octo.com]
> > Sent: 26 February 2002 21:23
> > To: ant-dev@jakarta.apache.org
> > Subject: Problem Logging in Tasks
> >
> > Hi,
> >
> > For some reason the log("xxx", Project.MSG_VERBOSE) code that I have
> in
> > my custom tasks do not get logged when I run ant eith the -verbose
> flag
> > on. Any idea why ?
> >
> > I've looked at how others tasks were doing their logging and I can't
> see
> > the difference from my code apart from the fact that they are inside
> > ant.jar/optional.jar.
> >
> > Here is how I define my task :
> >
> > <taskdef name="runservertests"
> > classname="org.apache.cactus.ant.RunServerTestsTask">
> >   <classpath>
> >     <pathelement location="${cactus.ant.jar}"/>
> >     <pathelement path="${java.class.path}"/>
> >   </classpath>
> > </taskdef>
> >
> > Here is a sample of what I do :
> >
> > public class RunServerTestsTask extends Task
> > {
> >     public void init()
> >     {
> >         this.startHelper = new StartServerHelper(this);
> >         this.stopHelper = new StopServerHelper(this);
> >     }
> > [...]
> > }
> >
> > public class StartServerHelper implements Runnable
> > {
> >     private Task task;
> >
> >     public StartServerHelper(Task theTask)
> >     {
> >         this.task = theTask;
> >     }
> >
> >     public void execute() throws BuildException
> >     {
> >         this.task.log("xxx", Project.MSG_VERBOSE);
> > [...]
> >
> >
> > Thanks for your help.
> > -Vincent
> >
> > P.S.: I do realize there must be something very obvious but I've
been
> > banging my head for a few hours already and I'm stuck ... :-)
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <mailto:ant-dev-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail:
> <mailto:ant-dev-help@jakarta.apache.org>
> >
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:
<mailto:ant-dev-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:ant-dev-help@jakarta.apache.org>
> 




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