Created: (LUCENE-810) provide a isClosed() method in Searcher class

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Created: (LUCENE-810) provide a isClosed() method in Searcher class

Sebastian Nagel (Jira)
provide a isClosed() method in Searcher class
---------------------------------------------

                 Key: LUCENE-810
                 URL: https://issues.apache.org/jira/browse/LUCENE-810
             Project: Lucene - Java
          Issue Type: New Feature
          Components: Search
    Affects Versions: 2.0.0
         Environment: windows 2003, Jdk 5, Apache Tomcat 5.5.17
            Reporter: mohammad norouzi


In our project we need to build a searcher pooling system, so a isClosed() method is required for testing if searcher is closed then try to re-open that. we dont want to close IndexReader since it is fixed for a searcher.

--
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: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Resolved: (LUCENE-810) provide a isClosed() method in Searcher class

Sebastian Nagel (Jira)

     [ https://issues.apache.org/jira/browse/LUCENE-810?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Hoss Man resolved LUCENE-810.
-----------------------------

    Resolution: Won't Fix

> provide a isClosed() method in Searcher class
> ---------------------------------------------
>
>                 Key: LUCENE-810
>                 URL: https://issues.apache.org/jira/browse/LUCENE-810
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>    Affects Versions: 2.0.0
>         Environment: windows 2003, Jdk 5, Apache Tomcat 5.5.17
>            Reporter: mohammad norouzi
>
> In our project we need to build a searcher pooling system, so a isClosed() method is required for testing if searcher is closed then try to re-open that. we dont want to close IndexReader since it is fixed for a searcher.

--
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: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Commented: (LUCENE-810) provide a isClosed() method in Searcher class

Sebastian Nagel (Jira)
In reply to this post by Sebastian Nagel (Jira)

    [ https://issues.apache.org/jira/browse/LUCENE-810?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12475141 ]

Hoss Man commented on LUCENE-810:
---------------------------------

please consult the java-user mailing list with questions for discussion before opening new bugs/ feature request issues.

If you don't want an IndexReader to be closed when closing an IndexSearcher, this can be done by using the IndexSearcher(IndexReader) constructor (an IndexSearcher will only close it's IndexReader if it opened it in the first place)

Even if i've missudnerstood your question, and you absolutely need an isClosed() method, this can easily be added by subclassing IndexSearcher in your application...


  public MySearcher extends IndexSearcher {
     /* ... define whatever constructors you want ... */
     boolean closed = false;
     public void close() {
        closed=true;
        super.close();
     }
     public isClosed() { return closed; }    
  }


> provide a isClosed() method in Searcher class
> ---------------------------------------------
>
>                 Key: LUCENE-810
>                 URL: https://issues.apache.org/jira/browse/LUCENE-810
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>    Affects Versions: 2.0.0
>         Environment: windows 2003, Jdk 5, Apache Tomcat 5.5.17
>            Reporter: mohammad norouzi
>
> In our project we need to build a searcher pooling system, so a isClosed() method is required for testing if searcher is closed then try to re-open that. we dont want to close IndexReader since it is fixed for a searcher.

--
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: [hidden email]
For additional commands, e-mail: [hidden email]