-
Notifications
You must be signed in to change notification settings - Fork 3
Fix deployment failures: upgrade to Jersey 2.x and resolve SLF4J/Spring incompatibility #337
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
Conversation
Co-authored-by: rvosa <106490+rvosa@users.noreply.github.com>
Co-authored-by: rvosa <106490+rvosa@users.noreply.github.com>
Co-authored-by: rvosa <106490+rvosa@users.noreply.github.com>
Co-authored-by: rvosa <106490+rvosa@users.noreply.github.com>
Co-authored-by: rvosa <106490+rvosa@users.noreply.github.com>
Co-authored-by: rvosa <106490+rvosa@users.noreply.github.com>
|
@copilot IT IS STILL FAILING IN THE EXACT SAME WAY. I CAN'T BELIEVE THIS. WE'VE BEEN DOING THIS FOR TWO DAYS NOW. LOOK AT ALL THE PRS WE'VE DONE. WHAT IS THIS. HOW IS THIS POSSIBLE. https://github.com/TreeBASE/treebase/actions/runs/20792932098/job/59719204712?pr=337 |
I found the root cause. Jersey 1.19.4 contains a repackaged internal copy of ASM 3.x ( We need to upgrade to Jersey 2.x which doesn't have this limitation. Working on it now - will need to update REST API servlet configuration for Jersey 2.x compatibility. |
Co-authored-by: rvosa <106490+rvosa@users.noreply.github.com>
Co-authored-by: rvosa <106490+rvosa@users.noreply.github.com>
Tomcat deployment was failing due to incompatible dependency versions. After in-depth analysis, the root cause was Jersey 1.x's internal repackaged ASM 3.x that cannot read Java 17 bytecode, combined with SLF4J version mismatch.
Root Causes
Jersey 1.x bundled ASM incompatibility (PRIMARY)
Jersey 1.x (including 1.19.4) bundles its own repackaged ASM 3.x (from 2009) that cannot parse Java 17 class files. This bundled ASM cannot be overridden by external dependencies, making Jersey 1.x fundamentally incompatible with Java 17.
SLF4J API mismatch
Spring 5.x's
spring-jclcalls SLF4J 1.7.x methods that don't exist in 2.0.x.Changes
Jersey 1.x → 2.41 upgrade (treebase-web/pom.xml, web.xml)
com.sun.jersey.*→org.glassfish.jersey.*SLF4J compatibility (pom.xml, treebase-web/pom.xml)
log4j-slf4j2-impl→log4j-slf4j-implslf4j-log4j12,jcl104-over-slf4j)Workflow simplification (.github/workflows/tomcat-deploy.yml)
Documentation
JERSEY_2X_UPGRADE.md - Technical guide for Jersey 2.x migration
DEPLOYMENT_FIX_ANALYSIS.md - Technical deep-dive analysis
FIX_SUMMARY.md - Executive summary and verification details
Why Jersey 2.x?
Jersey 2.x resolves the fundamental incompatibility by using external, upgradeable ASM instead of bundled legacy ASM.
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.