Return-Path: Mailing-List: contact ant-dev-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list ant-dev@jakarta.apache.org Received: (qmail 90712 invoked from network); 22 Nov 2000 07:59:09 -0000 Received: from bodewig.bost.de (root@195.227.98.11) by locus.apache.org with SMTP; 22 Nov 2000 07:59:09 -0000 Received: (from bodewig@localhost) by bodewig.bost.de (8.9.3/8.9.3) id IAA05639; Wed, 22 Nov 2000 08:59:08 +0100 X-Authentication-Warning: bodewig.bost.de: bodewig set sender to bodewig@apache.org using -f To: ant-dev@jakarta.apache.org Subject: Re: Why does the echo task output to System.out? (Was: RE: [submi t] I ntegration of Ant into Visual Age for Java) References: <003801c053b4$faed2c80$80dc1fcb@cognet.com.au> From: Stefan Bodewig Date: 22 Nov 2000 08:59:08 +0100 In-Reply-To: "Conor MacNeill"'s message of "Tue, 21 Nov 2000 23:17:13 +1100" Message-ID: Lines: 24 User-Agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Channel Islands) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Conor MacNeill wrote: > We are also going to need to handle the case of java classes, > executed by ant in-VM, which write to System.out. This output should > be directed to the log with MSG_INFO for System.out and MSG_WARN for > System.err. We will probably need a LogOutputStream for this. This > is similar to the LogStreamHandler for java classes run in a > separate VM. There already is a LogOutputStream class for exactly this type of thing. I had modified the java task to support output files shortly after the release, so it should be quite easy to plug in a LogOutputStream into it. Other tasks like may have different issues. One thing to note here ( task) is that we are going to face the same problem we had with in a slightly different way. This task has a outfile attribute to redirect the output - and obviously nobody ever thought of using the logging system in any other situation - so it's either write to the file or to Ant's logging system (to ensure it ends up somewhere where the user can read it). Stefan