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

Uwe Schindler closed LUCENE-2448.
---------------------------------

    Resolution: Invalid

This is not a bug.

Lucene 3.0 changed the stored fields to no longer support compressed fields. To 
mark an already "converted" (removed compression) stored fields file, the 
version is upgraded to the 3.0 one. Lucene 2.9 is then no longer able to read 
the index because of the upgraded version.

Theoretically it could - when i implemented the stored field upgrade with 
Michael Busch, I thought about adding support for the higher version as an 
"alias" to 2.9, but the release schedule for 2.9 was too fast. The best 
solution would be to force 2.9 to *always* write stored field segments with the 
old version, but 2.9 should also be able to *readonly* the new version 
signature.

> Exception in thread "main" org.apache.lucene.index.CorruptIndexException: 
> Incompatible format version: 2 expected 1 or lower
> ----------------------------------------------------------------------------------------------------------------------------
>
>                 Key: LUCENE-2448
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2448
>             Project: Lucene - Java
>          Issue Type: Bug
>    Affects Versions: 2.9.1
>         Environment: Windows Vista Home Premium, Lucene version 2.9.1, JRE6
>            Reporter: Bill Herbert
>         Attachments: _0.cfs, _0.cfx, AddressBookSearcher.java, segments.gen, 
> segments_2
>
>
> The attached code is indended to search the contents of an indexed file.  
> Upon execution, it generates the following stacktrace.  I will appreciate any 
> assistance in interpreting and correcting this error.  Also, how should I 
> address the warning about the depreciated API.
> Thanks,  Bill
> C:\lucene-3.0.1\src>javac AddressBookSearcher.java
> Note: AddressBookSearcher.java uses or overrides a deprecated API.
> Note: Recompile with -Xlint:deprecation for details.
> C:\lucene-3.0.1\src>java AddressBookSearcher
> Exception in thread "main" org.apache.lucene.index.CorruptIndexException: 
> Incomp
> atible format version: 2 expected 1 or lower
>         at org.apache.lucene.index.FieldsReader.<init>(FieldsReader.java:117)
>         at 
> org.apache.lucene.index.SegmentReader$CoreReaders.openDocStores(Segme
> ntReader.java:277)
>         at org.apache.lucene.index.SegmentReader.get(SegmentReader.java:640)
>         at org.apache.lucene.index.SegmentReader.get(SegmentReader.java:599)
>         at 
> org.apache.lucene.index.DirectoryReader.<init>(DirectoryReader.java:1
> 04)
>         at 
> org.apache.lucene.index.DirectoryReader$1.doBody(DirectoryReader.java
> :76)
>         at 
> org.apache.lucene.index.SegmentInfos$FindSegmentsFile.run(SegmentInfo
> s.java:704)
>         at 
> org.apache.lucene.index.DirectoryReader.open(DirectoryReader.java:69)
>         at org.apache.lucene.index.IndexReader.open(IndexReader.java:476)
>         at org.apache.lucene.index.IndexReader.open(IndexReader.java:243)
>         at org.apache.lucene.index.IndexReader.open(IndexReader.java:222)
>         at 
> org.apache.lucene.search.IndexSearcher.<init>(IndexSearcher.java:62)
>         at AddressBookSearcher.main(AddressBookSearcher.java:22)

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

Reply via email to