New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move to JAVA 1.7 with the once 1.1 is released following the upcoming Lucene 4.8 Release #5421

Closed
s1monw opened this Issue Mar 13, 2014 · 5 comments

Comments

Projects
None yet
2 participants
@s1monw
Contributor

s1monw commented Mar 13, 2014

Lucene moved to Java 1.7 as the minimum requirement here is the reasoning / official announcement:

the Apache Lucene/Solr committers decided with a large majority on the vote to require Java 7 for the next minor release of Apache Lucene and Apache Solr (version 4.8)!
Support for Java 6 by Oracle  already ended more than a year ago and Java 8 is coming out in a few days.

The next release will also contain some improvements for Java 7:
- Better file handling (especially on Windows) in the directory implementations. Files can now be deleted on windows, although the index is still open - like it was always possible on Unix environments (delete on last close semantics).
- Speed improvements in sorting comparators: Sorting now uses Java 7's own comparators for integer and long sorts, which are highly optimized by the Hotspot VM..

If you want to stay up-to-date with Lucene and Solr, you should upgrade your infrastructure to Java 7. Please be aware that you must use at least use Java 7u1.
The recommended version at the moment is Java 7u25. Later versions like 7u40, 7u45,... have a bug causing index corrumption. Ideally use the Java 7u60 prerelease, which has fixed this bug. Once 7u60 is out, this will be the recommended version.
In addition, there is no Oracle/BEA JRockit available for Java 7, use the official Oracle Java 7. JRockit was never working correctly with Lucene/Solr (causing index corrumption), so this should not be an issue for you. Please also review our list of JVM bugs: http://wiki.apache.org/lucene-java/JavaBugs

Apache Lucene and Apache Solr were also heavily tested with all prerelease versions of Java 8, so you can also give it a try! Looking forward to the official Java 8 release next week - I will run my indexes with that version for sure!

We should move as well and make Java 1.7 the minimum requirement to run Elasticsearch once we move to Lucene 4.8. Note, this is not yet release and it will roughly take a month or so until it will. I am putting es version 1.2.0 on this issue and mark it breaking to notify users. This means everything >= v1.2.0 will need Java 1.7 and will not run on 1.6 to be absolutely clear.

@s1monw s1monw self-assigned this Mar 13, 2014

@dadoonet

This comment has been minimized.

Member

dadoonet commented Mar 13, 2014

I think we should add this to our pom.xml:

<build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <version>1.3.1</version>
        <executions>
          <execution>
            <id>enforce-versions</id>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <rules>
                <requireJavaVersion>
                  <version>1.7</version>
                </requireJavaVersion>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>

See also: http://maven.apache.org/enforcer/enforcer-rules/requireJavaVersion.html

@s1monw

This comment has been minimized.

Contributor

s1monw commented Mar 13, 2014

++ to the enforcer... @dadoonet do you wanna add it to master / or provide a PR?

@dadoonet

This comment has been minimized.

Member

dadoonet commented Mar 13, 2014

Sure.

@dadoonet

This comment has been minimized.

Member

dadoonet commented Mar 13, 2014

@s1monw done in my repo with dadoonet@4e926d8 Wanna check?

BTW, I marked it as 1.2.0 although this change will be pushed in master (2.0.0). I guess that when 1.1.0 will be released I could cherry pick this commit and push it in branch 1.x, right?
Which other label I should use to mark this issue? (test?)

s1monw added a commit to s1monw/elasticsearch that referenced this issue Mar 27, 2014

@s1monw

This comment has been minimized.

Contributor

s1monw commented Mar 27, 2014

fixed

@s1monw s1monw closed this Mar 27, 2014

@s1monw s1monw changed the title from Move to JAVA 1.7 with the Lucene 4.8 Release to Move to JAVA 1.7 with the once 1.1 is release following the upcoming Lucene 4.8 Release Mar 27, 2014

@s1monw s1monw changed the title from Move to JAVA 1.7 with the once 1.1 is release following the upcoming Lucene 4.8 Release to Move to JAVA 1.7 with the once 1.1 is released following the upcoming Lucene 4.8 Release Mar 27, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment