Skip to content
Merged
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
4 changes: 4 additions & 0 deletions ci/run_ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ integration_tests() {
mvn -T10 -B --no-transfer-progress clean install -DskipTests
echo "Start perf tests"
cd "$ROOT"/integration_tests/perftests
echo "Start latest jdk tests"
cd "$ROOT"/integration_tests/latest_jdk_tests
export JAVA_HOME="$ROOT/zulu17.44.17-ca-crac-jdk17.0.8-linux_x64"
export PATH=$JAVA_HOME/bin:$PATH
mvn -T10 -B --no-transfer-progress clean test
echo "Start jdk compatibility tests"
cd "$ROOT"/integration_tests/jdk_compatibility_tests
Expand Down
68 changes: 68 additions & 0 deletions integration_tests/latest_jdk_tests/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--

Copyright 2023 The Fury Authors

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>org.furyio</groupId>
<artifactId>latest_jdk_tests</artifactId>
<version>0.2.0-SNAPSHOT</version>

<properties>
<maven.compiler.source>17</maven.compiler.source>
<maven.compiler.target>17</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

<dependencies>
<dependency>
<groupId>org.furyio</groupId>
<artifactId>fury-core</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.furyio</groupId>
<artifactId>fury-test-core</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
<version>2.5.0</version>
<configuration>
<java>
<googleJavaFormat>
<version>1.7</version>
<style>GOOGLE</style>
</googleJavaFormat>
<excludes>
<exclude>**/generated/*.java</exclude>
</excludes>
</java>
</configuration>
</plugin>
</plugins>
</build>

</project>
18 changes: 18 additions & 0 deletions java/fury-core/src/main/java/io/fury/util/RecordComponent.java
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
/*
* Copyright 2023 The Fury Authors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package io.fury.util;

import java.lang.reflect.Method;
Expand All @@ -8,6 +24,8 @@
* class.
*
* <p>See more details in java.lang.reflect.RecordComponent.
*
* @author chaokunyang
*/
public final class RecordComponent {
// declaring class
Expand Down
24 changes: 22 additions & 2 deletions java/fury-core/src/main/java/io/fury/util/RecordUtils.java
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
/*
* Copyright 2023 The Fury Authors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package io.fury.util;

import io.fury.collection.Tuple2;
Expand All @@ -12,7 +28,11 @@
import java.lang.reflect.Type;
import java.util.Arrays;

/** Utils for java.lang.Record subclasses. */
/**
* Utils for java.lang.Record.
*
* @author chaokunyang
*/
@SuppressWarnings({"rawtypes"})
public class RecordUtils {
private static final Method IS_RECORD;
Expand Down Expand Up @@ -171,7 +191,7 @@ public static RecordComponent[] getRecordComponents(Class<?> cls) {
return recordComponentsCache.get(cls);
}

/** Returns the record canonical constructor */
/** Returns the record canonical constructor. */
public static Tuple2<Constructor, MethodHandle> getRecordConstructor(Class<?> cls) {
return ctrCache.get(cls);
}
Expand Down