You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Using spring cloud (spring-cloud-aws-starter-sqs) with version 3.0.2 for my async Sqs listener (annotated with @SqsListener) I face an issue with deserialization of LocalDateTime and setting up proper ObjectMapper for the process.
[sdk-async-response-0-3] ERROR i.a.c.s.l.s.AbstractPollingMessageSource - Error processing message
org.springframework.messaging.converter.MessageConversionException: Could not read JSON: Java 8 date/time type java.time.LocalDateTime not supported by default: add Module "com.fasterxml.jackson.datatype:jackson-datatype-jsr310" to enable handling
How can I configure custom (or even default spring) objectMapper for deserialization?
Hi @atakume, this is a known issue which is in the process of being addressed. See #721. In the meantime that ticket contains a couple of suggested workarounds (read from the top), including one I contributed here.
Type: Bug
Component:
"SQS"
Describe the bug
Using spring cloud (spring-cloud-aws-starter-sqs) with version 3.0.2 for my async Sqs listener (annotated with @SqsListener) I face an issue with deserialization of LocalDateTime and setting up proper ObjectMapper for the process.
How can I configure custom (or even default spring) objectMapper for deserialization?
Sample
My listener method:
I tried by setting up configuration:
And by providing custom MappingJackson2MessageConverter like:
In both cases I got the same error (my configuration was omitted).
The text was updated successfully, but these errors were encountered: