| 1 | <!-- |
| 2 | Licensed to the Apache Software Foundation (ASF) under one or more |
| 3 | contributor license agreements. See the NOTICE file distributed with |
| 4 | this work for additional information regarding copyright ownership. |
| 5 | The ASF licenses this file to You under the Apache License, Version 2.0 |
| 6 | the "License"); you may not use this file except in compliance with |
| 7 | the License. You may obtain a copy of the License at |
| 8 | |
| 9 | http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | |
| 11 | Unless required by applicable law or agreed to in writing, software |
| 12 | distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | See the License for the specific language governing permissions and |
| 15 | limitations under the License. |
| 16 | --> |
| 17 | |
| 18 | # JRE Version Migration Guide |
| 19 | |
| 20 | If possible, use the same JRE major version at both index and search time. |
| 21 | When upgrading to a different JRE major version, consider re-indexing. |
| 22 | |
| 23 | Different Java versions may implement different versions of Unicode, |
| 24 | which will change the way some parts of Lucene treat your text. |
| 25 | |
| 26 | An (outdated) example: with Java 1.4, `LetterTokenizer` will split around the |
| 27 | character U+02C6, but with Java 5 it will not. This is because Java 1.4 |
| 28 | implements Unicode 3, but Java 5 implements Unicode 4. |
| 29 | |
| 30 | The version of Unicode supported by Java is listed in the documentation |
| 31 | of java.lang.Character class. For reference, Java versions after Java 11 |
| 32 | support the following Unicode versions: |
| 33 | |
| 34 | * Java 11, Unicode 10.0 |
| 35 | * Java 12, Unicode 11.0 |
| 36 | * Java 13, Unicode 12.1 |
| 37 | * Java 15, Unicode 13.0 |
| 38 | * Java 16, Unicode 13.0 |
| 39 | * Java 17, Unicode 13.0 |
| 40 | |
| 41 | In general, whether you need to re-index largely depends upon the data that |
| 42 | you are searching, and what was changed in any given Unicode version. For example, |
| 43 | if you are completely sure your content is limited to the "Basic Latin" range |
| 44 | of Unicode, you can safely ignore this. |