Spring Boot를 사용하여 drafts API를 구현하는 중에 문제가 발생했습니다. 다른 모든 API는 정상적으로 동작하지만, 이 API 하나만 계속 문제를 일으키고 있어 원인을 파악하지 못하고 있습니다.
혹시 이 부분을 구현해 보신 분이 계신가요? 문제 해결을 도와주실 수 있을까요? 제가 파악할 수 있는 오류를 예외에 담아 다음과 같이 공유합니다:
2023-05-15 15:09:44.310 ERROR 880 --- [nio-5000-exec-1] c.b.c.e.advice.ExceptionHandlerAdvice : ** Exception Leaked & captured : JsonParseException; Unrecognized token 'Optional': was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 'false')
at [Source: (String)"Optional[java.nio.HeapByteBuffer[pos=0 lim=16187 cap=16187]]"; line: 1, column: 9]
2023-05-15 15:09:44.315 DEBUG 880 --- [nio-5000-exec-1] s.s.w.c.SecurityContextPersistenceFilter : Cleared SecurityContextHolder to complete request
com.fasterxml.jackson.core.JsonParseException: Unrecognized token 'Optional': was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 'false')
아래는 페이로드와 URL "/drafts.json"입니다:
{
"draft_key": "new_topic",
"sequence": 94,
"data": {
"reply": "estaetwetweas sfasdf asdfa sdf as ",
"action": "createTopic",
"title": "test test test",
"categoryId": 5,
"archetypeId": "regular",
"metaData": null,
"composerTime": 19025,
"typingTime": 4800
}
}