-
Notifications
You must be signed in to change notification settings - Fork 18
feat: Add Java 25 support and normalize HTTP headers #320
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
base: master
Are you sure you want to change the base?
Conversation
aa4aa0c to
0667301
Compare
This seems to be a development utility that's unnecessary in this project. For development it can be brought in locally by putting it in local gradle init script, cf. https://github.com/dorongold/gradle-task-tree?tab=readme-ov-file#init-script-snippet
HTTP headers are case-insensitive by spec. Different HTTP libraries treat them differently — some preserve case, some change case. This can cause unnecessary differences in AppMap between library versions. This change normalizes all HTTP headers to lower case for consistency.
- Update GitHub Actions workflow to include Java 25 in the test matrix. - Upgrade Byte Buddy to 1.18.4 to support newer bytecode versions. - Introduce conditional patching for the Spring Petclinic test fixture, adding a specific patch for Java 25 compatibility. - Update JDBC and Spring Boot test modules to support Jakarta EE namespaces (Spring Boot 3.x) when running on newer Java versions. - Refactor test infrastructure to handle Gradle 9+ and newer JDKs, including Gretty and Gradle wrapper version adjustments. - Improve thread ID detection in Petclinic tests to account for differentiation in thread numbering between JDK versions. - Clean up hardcoded Java toolchains in classloading tests to allow running tests on the current environment's JDK.
b9d7921 to
96faae3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds support for Java 25 and normalizes HTTP header names to lowercase for consistency across different libraries and frameworks.
Changes:
- Added Java 25 to the CI/CD test matrix and upgraded byte-buddy to 1.18.4 for compatibility
- Introduced conditional build logic across test fixtures to handle Spring Boot 3.x (Jakarta EE) when running on Java 17+ and Java 25
- Normalized HTTP header names to lowercase in the HttpHeaders interface to prevent case-sensitivity discrepancies
Reviewed changes
Copilot reviewed 17 out of 19 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| .github/workflows/build-and-test.yml | Added Java 25 to the test matrix |
| agent/build.gradle | Upgraded byte-buddy dependency to 1.18.4 for Java 25 support |
| agent/src/main/java/com/appland/appmap/reflect/HttpHeaders.java | Normalized header names to lowercase in getHeaders() method |
| agent/test/petclinic/pom-java25.patch | New patch file for Petclinic to support Java 25 with Spring Boot 3.x |
| agent/test/petclinic/petclinic.bats | Updated test assertion to use lowercase "content-type" header |
| agent/test/petclinic/petclinic-tests.bats | Made thread ID test more robust by dynamically finding the main thread |
| agent/test/intellij/intellij.bats | Added skip logic for Java 25 (incompatible) |
| agent/test/helper.bash | Added logic to select Gradle 9.1 wrapper for Java 25 |
| agent/test/jdbc/build.gradle | Added Spring Boot version selection and javax->jakarta namespace transformation |
| agent/test/http_client/springboot/build.gradle | Added Spring Boot version selection based on Java version |
| agent/test/http_client/httpclient/build.gradle | Added mainClass/mainClassName compatibility handling for different Gradle versions |
| agent/test/http_client/setup_suite.bash | Removed unused SPRING_BOOT_VERSION variable |
| agent/test/gretty-tomcat/build.gradle | Added Gretty version selection based on Gradle version |
| agent/test/test-frameworks/build.gradle | Fixed TestNG dependency resolution to run during configuration phase |
| agent/test/classloading/settings.gradle | Removed foojay-resolver plugin |
| agent/test/classloading/lib/build.gradle | Removed Java toolchain specification |
| agent/test/classloading/app/build.gradle | Removed Java toolchain specification |
| agent/bin/test_projects | Added logic to select appropriate patch file and Petclinic version based on Java version |
| build.gradle | Removed unused tasktree plugin |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This PR updates the agent and build infrastructure to support Java 25. It includes updates to dependencies, build logic, and test fixtures to ensure compatibility with newer JDKs and Spring Boot versions.
Additionally, it includes a change to how HTTP headers are recorded to improve data consistency.
Java 25 Support
byte-buddyto 1.18.4.pom-java25.patch) for the Petclinic test fixture to support Java 25.Additional Changes
tasktreedependency to tidy up the build configuration.