ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Loughran <ste...@apache.org>
Subject Re: DO NOT REPLY [Bug 39842] - Add deleteonexit attribute to tempfile
Date Wed, 21 Jun 2006 16:28:35 GMT
Antoine Levy-Lambert wrote:
> Hi,
> 
> I also do not see any harm in this fix. It makes things easy for people who still use
Ant as a command line tool, be it to run makes or to move files around or deploy applications.

> 
> Regards,
> 
> Antoine

It was addressed to everyone.

File.deleteOnExit is only a hint. More interesting would be for the task 
to have a finalizer and for it to do cleanup then, which is likely to 
happen much much earlier in ide-hosted ant.

FWIW, the smartfrog TempFile logic does autodelete, but only as part of 
its terminate() method, which is called during undeployment. Even then, 
it tries to do it by hand first (if it is still there)

             if (delete && getFile() != null && getFile().exists()) {
                 if (!getFile().delete()) {
                     getFile().deleteOnExit();
                 }
             }

> 
> -------- Original-Nachricht --------
> Datum: Wed, 21 Jun 2006 08:18:03 -0700 (PDT)
> Von: Matt Benson <gudnabrsam@yahoo.com>
> An: Ant Developers List <dev@ant.apache.org>
> Betreff: Re: DO NOT REPLY [Bug 39842]  - Add deleteonexit attribute to tempfile
> 
>> --- bugzilla@apache.org wrote:
>> [SNIP]
>>> ------- Additional Comments From stevel@apache.org 
>>> 2006-06-21 09:17 -------
>>> You know this is pretty unreliable, dont you?
>>>
>>> It only kicks in when the process exits cleanly. In
>>> a project called by another
>>> project, the temp file will last until the outer
>>> project exits. If you are
>>> running Ant under an IDE, it wont kick in until the
>>> IDE exits itself, which
>>> could be weeks.
>>>
>> Was this addressed to me, Patrick (the requestor) or
>> both?  :)  Point taken, but is this actually
>> _undesirable_, or merely "unreliable"?  If the former,
>> we can roll back and call the bug WONTFIX, but I
>> confess that I really see no harm in it (obviously, or
>> I wouldn't have applied the change :).
>>
>> -Matt
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org
> 


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


Mime
View raw message