From RabbitMQ getting below JSON

{"PlateNo":"A125","DeviceId":"D152","Time":"/Date(1584260162000)/","Latitude":25.59483611111111,"Longitude":56.30596666666667,"Address":"Dibba, Fujairah, UAE","GPSSpeed":0,"IsValid":false}

After ObjectMapper,

How to format the Time2020欧洲杯时间表 field in the spring boot?

| |

2020欧洲杯时间表on date field use below annotation :-

  shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd@HH:mm:ss.SSSZ", locale = "en_GB")

and use below dependency :-

| |
  • get below error: Cannot deserialize value of type java.time.LocalDateTime from String "/Date(1584260162000)/": Failed to deserialize java.time.LocalDateTime: (java.time.format.DateTimeParseException) Text '/Date(1584260162000)/' could not be parsed at index 0 – Fazlan Ahamed Mar 19 at 9:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy2020欧洲杯时间表

Not the answer you're looking for? Browse other questions tagged or ask your own question.