mahout-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lance Norskog <goks...@gmail.com>
Subject Re: Is LDA Broken?
Date Sat, 21 May 2011 03:51:58 GMT
In Solr the practice is:

finalize() {
   if (! closed()) {
        log(WARN, "Hey! You didn't call close!");
        close();
    }
}

On Fri, May 20, 2011 at 7:09 PM, Ted Dunning <ted.dunning@gmail.com> wrote:
> +1
>
> (with exclamation marks)
>
> On Fri, May 20, 2011 at 7:07 PM, Sean Owen <srowen@gmail.com> wrote:
>
>> (Yes there is no guarantee when a reclaimable object is finalize()-ed and
>> removed. But as an aside, I believe we all understand that relying on that
>> behavior is wrong? Letting finalize() close a stream is a bug for sure. If
>> we're suggesting that's the case here, that's bad. All streams ought to be
>> explicitly closed.)
>>
>> On Fri, May 20, 2011 at 11:07 PM, Benson Margulies <bimargulies@gmail.com
>> >wrote:
>>
>> > Welcome to the Java garbage collector. You never know when it will
>> > close a stream.
>>
>



-- 
Lance Norskog
goksron@gmail.com

Mime
View raw message