tika-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael McCandless <luc...@mikemccandless.com>
Subject Re: Resource management patterns (Was: Tika leaves files open)
Date Thu, 01 Sep 2011 15:13:04 GMT
On Thu, Sep 1, 2011 at 7:26 AM, Jukka Zitting <jukka.zitting@gmail.com> wrote:
> Hi,
>
> [update subject, move to dev@]
>
> On Thu, Sep 1, 2011 at 12:41 PM, Uwe Schindler <uwe@thetaphi.de> wrote:
>> With our internal Lucene IOUtils it's even simplier, see javadocs :-)
>
> Yep, Lucene's version is certainly better.
>
>> It's just a few lines more code.
>
> It's still at least 7 lines of wrapper code compared to my 3 extra
> lines over the ARM pattern in Java 7. And you need an extra variable
> for each type of exceptions (what about Throwables?) that may be
> thrown by the code in question. In Tika that would typically be at
> least three variables, one each for IO-, SAX- and TikaExceptions.
>
> I think that's too high a price to pay for the IMHO rather marginal
> benefits. Let's wait for the upgrade to Java 7 and do it properly
> then.

OK let's wait for Java 7...

Mike McCandless

http://blog.mikemccandless.com

Mime
View raw message