Skip to content

Warning logs for JodaTime converters when using spring-boot-gcp-starter [DATACMNS-1594] #2023

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

Closed
spring-projects-issues opened this issue Oct 21, 2019 · 4 comments
Assignees
Labels
in: core Issues in core support status: declined A suggestion or change that we don't feel we should currently apply type: enhancement A general enhancement

Comments

@spring-projects-issues
Copy link

Bjorn Harvold opened DATACMNS-1594 and commented

The dependency spring-boot-gcp-starter brings with it Joda Time module causing Spring Data MongoDb to emit converter warnings

Created simple starter project to replicate. See attached.

2019-10-21 09:38:29.280 WARN 2206 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.LocalDateTime to class java.time.Instant as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 09:38:29.281 WARN 2206 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.Instant to class java.time.LocalDateTime as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 09:38:29.299 WARN 2206 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.LocalDateTime to class java.time.Instant as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 09:38:29.300 WARN 2206 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.Instant to class java.time.LocalDateTime as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.

Affects: 2.2 GA (Moore)

Attachments:

@spring-projects-issues
Copy link
Author

Oliver Drotbohm commented

Can you clarify on you mentioning JodaTime but the log output only talking about Java time types?

@spring-projects-issues
Copy link
Author

Bjorn Harvold commented

Hi Oliver Drotbohm. Posted that one too soon.

I took a closer look at the pom.xml I got when generating the test project. My project was using Spring Cloud Dependencies Greenwich .RELEASE and the test project was using Hoxton.M3. I was also using Spring Cloud GCP v1.1.1 and the test project is using 1.2.0.M3. The GCP milestone release does not have a dependency on Joda Time any longer.

It's still an issue with Spring Cloud GCP v1.1.x. Attaching an updated zip ball.

 

2019-10-21 14:24:18.330 WARN 57135 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.LocalDateTime to class org.joda.time.LocalDateTime as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 14:24:18.333 WARN 57135 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.LocalDateTime to class org.joda.time.LocalDateTime as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 14:24:18.335 WARN 57135 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.LocalDateTime to class java.time.Instant as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 14:24:18.335 WARN 57135 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.Instant to class java.time.LocalDateTime as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 14:24:18.355 WARN 57135 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.LocalDateTime to class org.joda.time.LocalDateTime as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 14:24:18.355 WARN 57135 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.LocalDateTime to class org.joda.time.LocalDateTime as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 14:24:18.356 WARN 57135 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.LocalDateTime to class java.time.Instant as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.
2019-10-21 14:24:18.356 WARN 57135 --- [ main] o.s.data.convert.CustomConversions : Registering converter from class java.time.Instant to class java.time.LocalDateTime as reading converter although it doesn't convert from a store-supported type! You might wanna check you annotation setup at the converter implementation.

@spring-projects-issues
Copy link
Author

Bjorn Harvold commented

FYI, I am having a similar issue with Apache CXF depending on Shibboleth which in turn depends on Joda Time. So it would be great if we could programmatically choose to include / exclude default converters such as Joda Time

@spring-projects-issues spring-projects-issues added status: waiting-for-feedback We need additional information before we can continue type: enhancement A general enhancement in: core Issues in core support labels Dec 30, 2020
@mp911de mp911de added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Dec 30, 2020
@mp911de mp911de assigned mp911de and unassigned odrotbohm Jan 18, 2021
@mp911de
Copy link
Member

mp911de commented Jan 18, 2021

Meanwhile, we've deprecated Joda support and we're planning to remove support for Joda time entirely with Spring Data 3.0 (#2276). Therefore, we don't intend to address this issue anymore.

@mp911de mp911de closed this as completed Jan 18, 2021
@mp911de mp911de added status: declined A suggestion or change that we don't feel we should currently apply and removed status: feedback-provided Feedback has been provided labels Jan 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core support status: declined A suggestion or change that we don't feel we should currently apply type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

3 participants