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

APOC to jdk 21 #688

Merged
merged 4 commits into from
Nov 19, 2024
Merged
Show file tree
Hide file tree
Changes from 3 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
4 changes: 2 additions & 2 deletions .github/actions/setup-jdk/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ name: "Setups JDK"
inputs:
java-version:
required: true
default: '17'
default: '21'

runs:
using: "composite"
steps:
- name: Set up JDK 17
- name: Set up JDK 21
uses: actions/setup-java@v3
with:
java-version: ${{ inputs.java-version }}
Expand Down
32 changes: 16 additions & 16 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
plugins {
id 'java-library'
id 'com.github.johnrengelman.shadow' version '7.1.0' apply false
id 'maven-publish'
id "com.github.hierynomus.license-report" version "0.16.1"
id "com.diffplug.spotless" version "6.22.0"
id("java-library")
id("com.github.johnrengelman.shadow") version "7.1.0" apply false
id("maven-publish")
id("com.github.hierynomus.license-report") version "0.16.1"
id("com.diffplug.spotless") version "6.22.0"
}

downloadLicenses {
Expand All @@ -14,7 +14,7 @@ downloadLicenses {

allprojects {
group = 'org.neo4j.procedure'
version = System.getenv('APOC_VERSION') ? System.getenv('APOC_VERSION') : '5.26.0'
version = System.getenv('APOC_VERSION') ? System.getenv('APOC_VERSION') : '2024.12.0'
archivesBaseName = 'apoc'
description = """neo4j-apoc-procedures"""
}
Expand Down Expand Up @@ -53,7 +53,7 @@ subprojects {
java {
target 'src/*/java/**/*.java'
removeUnusedImports()
palantirJavaFormat()
palantirJavaFormat('2.50.0')
}
}

Expand Down Expand Up @@ -81,16 +81,16 @@ subprojects {


java {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found one additional place which mentions Java 17, the annotation in ApocProcessor.java

}

task mySourcesJar(type: Jar) {
tasks.register('mySourcesJar', Jar) {
from sourceSets.main.allJava
archiveClassifier = 'sources'
}

task myJavadocJar(type: Jar) {
tasks.register('myJavadocJar', Jar) {
from javadoc
archiveClassifier = 'javadoc'
}
Expand All @@ -100,10 +100,10 @@ subprojects {
// neo4jDockerImage system property is used in TestContainerUtil
systemProperties 'user.language': 'en',
'user.country': 'US',
'neo4jDockerImage': project.hasProperty("neo4jDockerEeOverride") ? project.getProperty("neo4jDockerEeOverride") : 'neo4j:5.26.0-enterprise-debian',
'neo4jCommunityDockerImage': project.hasProperty("neo4jDockerCeOverride") ? project.getProperty("neo4jDockerCeOverride") : 'neo4j:5.26.0-debian',
'neo4jDockerImage': project.hasProperty("neo4jDockerEeOverride") ? project.getProperty("neo4jDockerEeOverride") : 'neo4j:2024.12.0-enterprise-debian',
'neo4jCommunityDockerImage': project.hasProperty("neo4jDockerCeOverride") ? project.getProperty("neo4jDockerCeOverride") : 'neo4j:2024.12.0-debian',
'coreDir': 'core',
'testDockerBundle': project.hasProperty("testDockerBundle") ? true : false,
'testDockerBundle': project.hasProperty("testDockerBundle"),
'org.neo4j.io.pagecache.tracing.cursor.DefaultPageCursorTracer.CHECK_REPORTED_COUNTERS': 'true' // Extra assertions in kernel

maxHeapSize = "5G"
Expand Down Expand Up @@ -147,7 +147,7 @@ subprojects {

configurations.configureEach {
resolutionStrategy.eachDependency { details ->
if (details.requested.group == 'io.netty' && !details.requested.name.contains('netty-tcnative') && !details.requested.name.equals('netty')) {
if (details.requested.group == 'io.netty' && !details.requested.name.contains('netty-tcnative') && details.requested.name != 'netty') {
details.useVersion '4.1.101.Final' // Use same Netty version as server
}
}
Expand All @@ -170,7 +170,7 @@ apply from: "licenses-source-header.gradle"

ext {
publicDir = "${project.rootDir}"
neo4jVersionEffective = project.hasProperty("neo4jVersionOverride") ? project.getProperty("neo4jVersionOverride") : "5.26.0"
neo4jVersionEffective = project.hasProperty("neo4jVersionOverride") ? project.getProperty("neo4jVersionOverride") : "2024.12.0"
testContainersVersion = '1.20.2'
apacheArrowVersion = '15.0.0'
}
7 changes: 4 additions & 3 deletions common/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -56,20 +56,21 @@ dependencies {
testImplementation group: 'org.mockito', name: 'mockito-core', version: '4.2.0'
testImplementation group: 'pl.pragmatists', name: 'JUnitParams', version: '1.1.1'

configurations.all {
configurations.configureEach {
exclude group: 'org.slf4j', module: 'slf4j-nop'
exclude group: 'ch.qos.logback', module: 'logback-classic'
exclude group: 'org.ow2.asm', module: 'asm'
}
}


task testJar(type: Jar, dependsOn: testClasses) {
tasks.register('testJar', Jar) {
dependsOn testClasses
archiveClassifier = 'tests'
from sourceSets.test.output
}

task copyRuntimeLibs(type: Copy) {
tasks.register('copyRuntimeLibs', Copy) {
into "lib"
from configurations.testRuntimeClasspath
}
Expand Down
2 changes: 1 addition & 1 deletion core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ publishing {
}
}

task copyRuntimeLibs(type: Copy) {
tasks.register('copyRuntimeLibs', Copy) {
into "lib"
from configurations.testRuntimeClasspath
}
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
3 changes: 2 additions & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
29 changes: 17 additions & 12 deletions gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,8 @@ done
# This is normally unused
# shellcheck disable=SC2034
APP_BASE_NAME=${0##*/}
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit

# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum
Expand Down Expand Up @@ -133,26 +131,29 @@ location of your Java installation."
fi
else
JAVACMD=java
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
if ! command -v java >/dev/null 2>&1
then
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
fi

# Increase the maximum file descriptors if we can.
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
case $MAX_FD in #(
max*)
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
# shellcheck disable=SC3045
# shellcheck disable=SC2039,SC3045
MAX_FD=$( ulimit -H -n ) ||
warn "Could not query maximum file descriptor limit"
esac
case $MAX_FD in #(
'' | soft) :;; #(
*)
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
# shellcheck disable=SC3045
# shellcheck disable=SC2039,SC3045
ulimit -n "$MAX_FD" ||
warn "Could not set maximum file descriptor limit to $MAX_FD"
esac
Expand Down Expand Up @@ -197,11 +198,15 @@ if "$cygwin" || "$msys" ; then
done
fi

# Collect all arguments for the java command;
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
# shell script including quotes and variable substitutions, so put them in
# double quotes to make sure that they get re-expanded; and
# * put everything else in single quotes, so that it's not re-expanded.

# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'

# Collect all arguments for the java command:
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# and any embedded shellness will be escaped.
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
# treated as '${Hostname}' itself on the command line.

set -- \
"-Dorg.gradle.appname=$APP_BASE_NAME" \
Expand Down
6 changes: 3 additions & 3 deletions readme.adoc
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
:readme:
:branch: 5.25
:branch: 2024.12.0
:docs: https://neo4j.com/docs/apoc/current
:apoc-release: 5.25.1
:neo4j-version: 5.25.1
:apoc-release: 2024.12.0
:neo4j-version: 2024.12.0
:img: https://raw.githubusercontent.com/neo4j/apoc/dev/images

https://community.neo4j.com[image:https://img.shields.io/discourse/users?logo=discourse&server=https%3A%2F%2Fcommunity.neo4j.com[Discourse users]]
Expand Down
Loading