2024-05-21T06:54:15.404+09:00
WARN 3156 --- [data-collection] [nio-8080-exec-6]
.w.s.m.s.DefaultHandlerExceptionResolver : Resolved
[org.springframework.http.converter.HttpMessageNotReadableException:
JSON parse error: Cannot deserialize value of type
`java.time.LocalDateTime` from String "2023-01-01 16:00:00":
Failed to deserialize java.time.LocalDateTime:
(java.time.format.DateTimeParseException) Text '2023-01-01 16:00:00'
could not be parsed at index 10]
2. 요청 방법
"recordedAt": "2023-01-01 16:00:00" 이렇게 요청하면서 생긴 에러입니다.
3. 원인
10번째 index에서 파싱 실패라는 내용을 확인할 수 있습니다.
timestamp를 확인해보면 yyyy-MM-ddTHH:mm:ss 형태인 것을 확인할 수 있습니다.
그렇기 때문에 요청 형식을 맞추면 해결할 수 있을거라 생각하고
이렇게 요청하여 문제를 해결했습니다.