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

custom check compilation failed #11302

Closed
123liuziming opened this issue May 8, 2024 · 4 comments
Closed

custom check compilation failed #11302

123liuziming opened this issue May 8, 2024 · 4 comments
Labels
bug Something isn't working needs triage New issue that requires triage

Comments

@123liuziming
Copy link
Contributor

Describe the bug

[root@iZrj9b2ssilaoq3m1m4646Z musi-test]# git clone https://github.com/open-telemetry/opentelemetry-java-instrumentation.git
正克隆到 'opentelemetry-java-instrumentation'...
remote: Enumerating objects: 397069, done.
remote: Counting objects: 100% (268/268), done.
remote: Compressing objects: 100% (157/157), done.
remote: Total 397069 (delta 62), reused 217 (delta 40), pack-reused 396801
接收对象中: 100% (397069/397069), 172.93 MiB | 12.74 MiB/s, 完成.
处理 delta 中: 100% (129715/129715), 完成.
cd [root@iZrj9b2ssilaoq3m1m4646Z musi-test]# cd opentelemetry-java-instrumentation/
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]# ./gradlew :instrumentation:spring:spring-cloud-gateway:spring-cloud-gateway-2.0:javaagent:test
> Task :custom-checks:compileJava FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':custom-checks:compileJava'.
> 错误: 无效的标记: -Xlint:-this-escape

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Get more help at https://help.gradle.org.

Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.7/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

BUILD FAILED in 10s
51 actionable tasks: 38 executed, 13 from cache
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]# Å^C
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]# ^C
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]# ./gradlew :instrumentation:spring:spring-cloud-gateway:spring-cloud-gateway-2.0:javaagent:test^C
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]# ^C
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]# ./gradlew cleanTest

Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.7/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

BUILD SUCCESSFUL in 11s
516 actionable tasks: 2 executed, 514 up-to-date
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]# ./gradlew clean

Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.7/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

BUILD SUCCESSFUL in 8s
521 actionable tasks: 500 executed, 21 up-to-date
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]# ./gradlew :instrumentation:spring:spring-cloud-gateway:spring-cloud-gateway-2.0:javaagent:test
> Task :custom-checks:compileJava FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':custom-checks:compileJava'.
> 错误: 无效的标记: -Xlint:-this-escape

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Get more help at https://help.gradle.org.

Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.7/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

BUILD FAILED in 8s
51 actionable tasks: 32 executed, 1 from cache, 18 up-to-date
[root@iZrj9b2ssilaoq3m1m4646Z opentelemetry-java-instrumentation]#

Steps to reproduce

clone latest code, and execute ./gradlew :instrumentation:spring:spring-cloud-gateway:spring-cloud-gateway-2.0:javaagent:test

Expected behavior

compile successfully

Actual behavior

compile failed

Javaagent or library instrumentation version

main branch

Environment

JDK:
OS:

Additional context

No response

@123liuziming 123liuziming added bug Something isn't working needs triage New issue that requires triage labels May 8, 2024
@Cirilla-zmh
Copy link

I've also run into a similar issue with my JDK major version being 17.
It seems that the problem was introduced by the MR at Build with JDK21 possibly. The custom-check lacks a maxJavaVersionSupported configuration, which leads to compilation failure when using JDK 17?

@laurit
Copy link
Contributor

laurit commented May 8, 2024

Currently jdk 21 is required for building the project.

@laurit
Copy link
Contributor

laurit commented May 8, 2024

Hopefully #11303 will get the project building with jdk17.

@123liuziming
Copy link
Contributor Author

Hopefully #11303 will get the project building with jdk17.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs triage New issue that requires triage
Projects
None yet
Development

No branches or pull requests

3 participants