Skip to content

Convert tomcat 10 tests from groovy to java#11420

Merged
laurit merged 2 commits into
open-telemetry:mainfrom
jaydeluca:convert-tomcat-10-tests
May 24, 2024
Merged

Convert tomcat 10 tests from groovy to java#11420
laurit merged 2 commits into
open-telemetry:mainfrom
jaydeluca:convert-tomcat-10-tests

Conversation

@jaydeluca

Copy link
Copy Markdown
Member

Related to #7195

@jaydeluca jaydeluca requested a review from a team May 21, 2024 23:50

@steverao steverao left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

It seems there is a compilation failed in the latest dependency. You can refer to https://scans.gradle.com/s/p2fu2s6egkes4
or you also can reproduce the error in your local by running the command ./gradlew :instrumentation:tomcat:tomcat-10.0:javaagent:compileTestJava -PtestLatestDeps=true

@jaydeluca

jaydeluca commented May 22, 2024

Copy link
Copy Markdown
Member Author

thanks @steverao , i am still investigating the cause (i also started a thread in slack)

From what I can tell, it looks like the problem is that in Tomcat 10 it switched from using the javax HttpServlet to using the Jakarta implementation, which has a Deprecation annotation that uses two arguments that can't be parsed by java 8?
https://github.com/apache/tomcat/blob/10.1.0/java/jakarta/servlet/http/HttpServlet.java#L108

@Deprecated(forRemoval = true, since = "Servlet 6.0")

I tried adding adding @SuppressWarnings("deprecation") but that didn't seem to do the trick. I also experimented with trying to make some changes to the gradle file to suppress the warnings but that didn't seem to work either.

@laurit laurit merged commit 98d0c3d into open-telemetry:main May 24, 2024
@jaydeluca jaydeluca deleted the convert-tomcat-10-tests branch November 9, 2024 02:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants