You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by "Andrzej Bialecki (JIRA)" <ji...@apache.org> on 2009/08/18 12:36:14 UTC

[jira] Created: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

UnsupportedOperationException may be thrown when using custom IndexReader
-------------------------------------------------------------------------

                 Key: SOLR-1366
                 URL: https://issues.apache.org/jira/browse/SOLR-1366
             Project: Solr
          Issue Type: Bug
          Components: search
    Affects Versions: 1.4
            Reporter: Andrzej Bialecki 
             Fix For: 1.4
         Attachments: searcher.patch

If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.

This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12744542#action_12744542 ] 

Mark Miller commented on SOLR-1366:
-----------------------------------



bq. This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. 

The replication handler uses it a lot (assuming its a file) - I almost feel we should add some javadoc about how using non FSDirectory based IndexReaders is supported. I'm not even fully sure myself.

Also, are we positive it behaves here correctly in SolrCore ?
{code}
      File indexDirFile = new File(getIndexDir()).getCanonicalFile();
      File newIndexDirFile = new File(newIndexDir).getCanonicalFile();
      
      if (newestSearcher != null && solrConfig.reopenReaders
          && indexDirFile.equals(newIndexDirFile)) {
{code}

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Resolved: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shalin Shekhar Mangar resolved SOLR-1366.
-----------------------------------------

    Resolution: Fixed

Committed revision 817801.

Thanks everybody!

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: searcher.patch, SOLR-1366.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Updated: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Andrzej Bialecki (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrzej Bialecki  updated SOLR-1366:
------------------------------------

    Attachment: searcher.patch

Patch that catches the exception and supplies IndexReader.toString() instead.

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Andrzej Bialecki (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12756652#action_12756652 ] 

Andrzej Bialecki  commented on SOLR-1366:
-----------------------------------------

+1 for adding a big red flag. My application depends on this functionality, and it's working well once I overrode a bunch of additional methods in IndexReader that deal with Directory, IndexCommit, index version, etc.

(A few details on this, and why my solution is not applicable in general case: I'm using ParallelReader, and the other indexes that I add are throwaways, i.e. I recreate them on each index refresh from external shared resources. So I basically short-circuited those methods that deal with directory and commits so that they return information from the main index. This way the file-based replication works as before for the main index).

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Grant Ingersoll (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12753704#action_12753704 ] 

Grant Ingersoll commented on SOLR-1366:
---------------------------------------

So, it seems for 1.4 we could fix this problem, add the documentation, and then open a new issue to deal with the replication problem in 1.5?

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Andrzej Bialecki (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12753761#action_12753761 ] 

Andrzej Bialecki  commented on SOLR-1366:
-----------------------------------------

I didn't make myself clear .. I fixed this for my application, where I control the implementation of IndexReader, but I wouldn't recommend this fix for general use. So this was just FYI.

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12745042#action_12745042 ] 

Shalin Shekhar Mangar commented on SOLR-1366:
---------------------------------------------

Yeah, ReplicationHandler assumes a file based IndexReader. We can document this clearly.

{quote}
.. I haven't looked into it yet, but perhaps this could be solved by extending the replication handler to support multiple dirs, and for those IndexReader that don't support directory() try asking for getSubReaders() and use their directory() ... 
{quote}

Yes but that becomes complicated very fast. You'd need to know the correct directory to which a newly downloaded file has to be written on the slave. You'd also need to re-open readers selectively and you'd need to change their directories (for cases where an existing file is to be deleted/replaced).

We anyway need to take a look at replication again after 1.4 with a focus on Lucene's NRT capabilities.

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Hoss Man (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12756634#action_12756634 ] 

Hoss Man commented on SOLR-1366:
--------------------------------

The core issue here seems to stem from incompatible assumptions between various pieces of code in Solr, and the new IndexReaderFactory functionality introduced in 1.4 by SOLR-243.

If we don't have a silver bullet for solving all the discrepancies before 1.4, then the safest approach seems to be making sure the documentation (and example configs) for IndexReaderFactory have big flashing red "Experimental!" disclaimers on them warning that using an IndexReaderFactory prevents certain other features from working (list all the ones we know about) and that the API for IndexReaderFactory may change at anytime w/o warning or be removed from future release if the problems can't be resolved.

I'm tempted to suggest we remove SOLR-243 altogether, but there are _some_ use cases of it that can work well for people, so it would be a shame to gut it completely.

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Andrzej Bialecki (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12744996#action_12744996 ] 

Andrzej Bialecki  commented on SOLR-1366:
-----------------------------------------

.. I haven't looked into it yet, but perhaps this could be solved by extending the replication handler to support multiple dirs, and for those IndexReader that don't support directory() try asking for getSubReaders() and use their directory() ...

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Updated: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shalin Shekhar Mangar updated SOLR-1366:
----------------------------------------

    Attachment: SOLR-1366.patch

How about this?

{code}
** Experimental Feature **
Please note - Using a custom IndexReaderFactory may prevent certain other features
from working. The API to IndexReaderFactory may change without warning or may even
be removed from future releases if the problems cannot be resolved.

** Features that may not work with custom IndexReaderFactory **
The ReplicationHandler assumes a disk-resident index. Using a custom
IndexReader implementation may cause incompatibility between ReplicationHandler and
may cause replication to not work correctly. See SOLR-1366 for details.
{code}

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch, SOLR-1366.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Assigned: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller reassigned SOLR-1366:
---------------------------------

    Assignee: Shalin Shekhar Mangar  (was: Mark Miller)

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: searcher.patch, SOLR-1366.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Andrzej Bialecki (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12744993#action_12744993 ] 

Andrzej Bialecki  commented on SOLR-1366:
-----------------------------------------

Indeed, that complicates the matter ... It looks like using a non-file based IndexReader breaks replication. This is not a regression from 1.3, but the functionality to specify custom IndexReaders will be available in 1.4, so it should be clearly stated in docs that it prevents replication from working properly, until we rectify this issue.

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Andrzej Bialecki (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12753289#action_12753289 ] 

Andrzej Bialecki  commented on SOLR-1366:
-----------------------------------------

FYI, for now I solved this by extending my IndexReader to support this call and return the original directory that lists all index files plus a few resources that I care about. However, this is just glossing over the deeper problem - replication handler shouldn't assume the directory is file-based.

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Andrzej Bialecki (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12758381#action_12758381 ] 

Andrzej Bialecki  commented on SOLR-1366:
-----------------------------------------

Looks good to me, +1.

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: searcher.patch, SOLR-1366.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Commented: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12753711#action_12753711 ] 

Yonik Seeley commented on SOLR-1366:
------------------------------------

bq. So, it seems for 1.4 we could fix this problem

What's the fix/workaround though?  Solr currently assumes a disk resident index, and the patch here makes up a directory... that doesn't seem like a good idea.  It also seems too late in the release cycle to try and abstract away from a disk index... potentially complex and invasive.

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


Re: [jira] Updated: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by Shalin Shekhar Mangar <sh...@gmail.com>.
On Fri, Aug 21, 2009 at 3:20 AM, Chris Hostetter
<ho...@fucit.org>wrote:

>
> : Shalin Shekhar Mangar updated SOLR-1366:
> : ----------------------------------------
> :
> :     Component/s: replication (java)
>
> the issue seems broader then just replication ... i would change this back
> to a generic "search" component, and open new related issue(s) for
> replication (documentation vs custom reader support) ... some pieces of
> this may make it into 1.4 and some may not, so we'll want to track
> seperately.
>
>
I just added "replication" in addition to "search" to the components field
so that this issue shows up against both. I'll open a new issue for the
documentation updates.

-- 
Regards,
Shalin Shekhar Mangar.

Re: [jira] Updated: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by Chris Hostetter <ho...@fucit.org>.
: Shalin Shekhar Mangar updated SOLR-1366:
: ----------------------------------------
: 
:     Component/s: replication (java)

the issue seems broader then just replication ... i would change this back 
to a generic "search" component, and open new related issue(s) for 
replication (documentation vs custom reader support) ... some pieces of 
this may make it into 1.4 and some may not, so we'll want to track 
seperately.



-Hoss


[jira] Updated: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shalin Shekhar Mangar updated SOLR-1366:
----------------------------------------

    Component/s: replication (java)

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: replication (java), search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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


[jira] Assigned: (SOLR-1366) UnsupportedOperationException may be thrown when using custom IndexReader

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1366?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller reassigned SOLR-1366:
---------------------------------

    Assignee: Mark Miller

> UnsupportedOperationException may be thrown when using custom IndexReader
> -------------------------------------------------------------------------
>
>                 Key: SOLR-1366
>                 URL: https://issues.apache.org/jira/browse/SOLR-1366
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 1.4
>            Reporter: Andrzej Bialecki 
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: searcher.patch
>
>
> If a custom IndexReaderFactory is specifiedd in solrconfig.xml, and IndexReader-s that it produces don't support IndexReader.directory() (such as is the case with ParallelReader or MultiReader) then an uncaught UnsupportedOperationException is thrown.
> This call is used only to retrieve the full path of the directory for informational purpose, so it shouldn't lead to a crash. Instead we could supply other available information about the reader (e.g. from its toString() method).

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