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

Upgrading to Spring Boot 2.5.0 leads to a startup warning from Jackson about Kotlin #26727

Closed
Bas83 opened this issue Jun 1, 2021 · 3 comments
Assignees
Labels
type: bug A general bug
Milestone

Comments

@Bas83
Copy link

Bas83 commented Jun 1, 2021

After migrating to Spring Boot 2.5.0 I get the following warning during startup:

WARN | o.s.h.c.j.Jackson2ObjectMapperBuilder | For Jackson Kotlin classes support please add "com.fasterxml.jackson.module:jackson-module-kotlin" to the classpath

Another person posting this StackOverflow question has this issue as well, but there is no clear/easy solution for it without code changes.
Just like this person I am not using Kotlin at all. Please make it easy to exclude Kotlin from autoconfiguration (as for example like with ThymeLeaf with exclude = {ThymeleafAutoConfiguration.class}, or maybe even solve this automatically for the user entirely.

@snicoll
Copy link
Member

snicoll commented Jun 1, 2021

@Bas83 thanks for the report but that warning is logged by Spring Framework based on the presence of a kotlin-specific jar. The SO question you've shared has a comment that links to spring-projects/spring-framework#26962.

Can you please confirm your application uses Spring Security?

@snicoll snicoll added status: waiting-for-feedback We need additional information before we can continue status: waiting-for-triage An issue we've not yet triaged labels Jun 1, 2021
@snicoll snicoll changed the title Make it easy to exclude Kotlin entirely, or do this automatically, to avoid the following startup warning from Jackson: For Jackson Kotlin classes support please add "com.fasterxml.jackson.module:jackson-module-kotlin" to the classpath Upgrading to Spring Boot 2.5.0 leads to a startup warning from Jackson about Kotlin Jun 1, 2021
@Bas83
Copy link
Author

Bas83 commented Jun 1, 2021

Yes I am using Spring Security. Should I report this to them instead? In your link I found this issue: spring-projects/spring-security#9811

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Jun 1, 2021
@snicoll
Copy link
Member

snicoll commented Jun 1, 2021

Thanks for confirming. Yes, that's the root cause of your issue. Please subscribe to that issue for further update. On our side, we'll add a temporary exclude as I am not sure that Spring Security 5.5.1 will be out before Spring Boot 2.5.1.

@snicoll snicoll added type: bug A general bug and removed status: feedback-provided Feedback has been provided status: waiting-for-triage An issue we've not yet triaged labels Jun 1, 2021
@snicoll snicoll self-assigned this Jun 1, 2021
@snicoll snicoll added this to the 2.5.1 milestone Jun 1, 2021
@snicoll snicoll closed this as completed in 7b490f0 Jun 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

No branches or pull requests

3 participants