lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Earwin Burrfoot (JIRA)" <>
Subject [jira] Commented: (LUCENE-2339) Allow Directory.copy() to accept a collection of file names to be copied
Date Wed, 24 Mar 2010 21:47:27 GMT


Earwin Burrfoot commented on LUCENE-2339:

bq. closeSafely is not exactly what I had in mind about closeNoException because it forces
you to catch the IOE if you don't declare you throw it
closeSafely wraps Closeable.close(), which declares IOException. Thus, you don't have to declare
or discard anything new. As a matter of fact it encapsulates exact same code we're seeing
copypasted (with varying degrees of success) all around Lucene.

As for RuntimeExceptions, I had ones in my Directory implementation, and it flew right through
Lucene. When I asked our brainiacs if that is okay, they said that anything expected should
be wrapped with IOException, as the operation is zero-cost (for no-exception-happened case),
and anything unexpected should kill your app in a blaze of glory. I see the point in that,
if I squint hard enough.

Mike, please mark that closeSagely with whatever.experimental? I think the signature may change,
as it gets used in more places, like that type parameter may be an overkill.

> Allow Directory.copy() to accept a collection of file names to be copied
> ------------------------------------------------------------------------
>                 Key: LUCENE-2339
>                 URL:
>             Project: Lucene - Java
>          Issue Type: Improvement
>            Reporter: Earwin Burrfoot
>            Assignee: Michael McCandless
>         Attachments: LUCENE-2339.patch, LUCENE-2339.patch, LUCENE-2339.patch, LUCENE-2339.patch,
> Par example, I want to copy files pertaining to a certain commit, and not everything
there is in a Directory.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message