[BUG] JSONB not support input type TIMESTAMP_SECONDS
- Dominant language
- Java
- Stars
- 4.4k
- Forks
- 613
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 6
Description
### 问题描述
*简要描述您碰到的问题。*
JSONB JSONB.parseObject not support input type TIMESTAMP_SECONDS
### 环境信息
*请填写以下信息:*
- JDK信息: [e.g.:Openjdk 1.8.0_312]
- 版本信息:[e.g.:Fastjson2 2.0.60]
### 重现步骤
*如何操作可以重现该问题:*
com.alibaba.fastjson2.JSONException: fieldName not support input type TIMESTAMP_SECONDS -84, offset 1
2025-10-27T12:31:55.458071287Z at com.alibaba.fastjson2.JSONReaderJSONB.readFieldNameHashCodeError(JSONReaderJSONB.java:1628) ~[fastjson2-2.0.60.jar!/:?]
2025-10-27T12:31:55.458074955Z at com.alibaba.fastjson2.JSONReaderJSONB.readFieldNameHashCode(JSONReaderJSONB.java:1530) ~[fastjson2-2.0.60.jar!/:?]
at com.alibaba.fastjson2.reader.ORG_4_18RequestParam.readJSONBObject(Unknown Source) ~[?:?]
2025-10-27T12:31:55.458092250Z at com.alibaba.fastjson2.JSONB.parseObject(JSONB.java:734) ~[fastjson2-2.0.60.jar!/:?]
//可在此输入示例代码
```
RequestParam request = JSONB.parseObject(record.value(), RequestParam.class);
Contributor guide
Research direction
Start at JSONB.parseObject and the JSONReaderJSONB.readFieldNameHashCode/readFieldNameHashCodeError locations named in the stack trace, using the RequestParam example to reproduce the TIMESTAMP_SECONDS failure. Done means the same JSONB input can be parsed without the unsupported-input-type exception.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100