Skip to content
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

Ability to use a java version >21 #2847

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ public static void main(String[] args) {

public static void checkVersion() {
int major = Runtime.getRuntime().version().feature();
if (major < 11 || major > 21) {
if (major < 21) {
throw new IllegalStateException(
"java version must be between 11 and 21, your version: " + major);
"java version must be at least 21, your version: " + major);
}
}

Expand Down
2 changes: 1 addition & 1 deletion build-tools/scriptDepVersions.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ ext {
"min-solrj-java-version" : "17",
"apache-rat": "0.15",
"commons-codec": "1.16.0",
"ecj": "3.36.0",
"ecj": "3.39.0",
"javacc": "7.0.12",
"jgit": "6.7.0.202309050840-r",
"flexmark": "0.64.8",
Expand Down
6 changes: 3 additions & 3 deletions gradle/validation/ecj-lint/ecj.javadocs.prefs
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annota
org.eclipse.jdt.core.compiler.annotation.nonnullisdefault=disabled
org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.codegen.targetPlatform=21
org.eclipse.jdt.core.compiler.compliance=21
org.eclipse.jdt.core.compiler.doc.comment.support=enabled
org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
Expand Down Expand Up @@ -93,4 +93,4 @@ org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disa
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=ignore
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.source=21
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@
import static org.apache.solr.common.util.JavaBinCodec.SOLRDOC;
import static org.apache.solr.common.util.JavaBinCodec.SOLRDOCLST;
import static org.apache.solr.common.util.JavaBinCodec.SOLRINPUTDOC;
import static org.apache.solr.common.util.JavaBinCodec.STR;
import static org.apache.solr.common.util.JavaBinCodec.TAG_AND_LEN;
import static org.apache.solr.common.util.JavaBinCodec.readVInt;

Expand Down Expand Up @@ -586,7 +585,7 @@ public void lazyRead(EntryImpl entry, StreamCodec codec) throws IOException {
},
// types that combine tag + length (or other info) in a single byte
_TAG_AND_LEN(TAG_AND_LEN, UPPER_3_BITS, null),
_STR(STR, UPPER_3_BITS, DataEntry.Type.STR) {
_STR(JavaBinCodec.STR, UPPER_3_BITS, DataEntry.Type.STR) {
@Override
public void lazyRead(EntryImpl entry, StreamCodec codec) throws IOException {
entry.size = readObjSz(codec, this);
Expand Down
Loading