fastjson2 icon indicating copy to clipboard operation
fastjson2 copied to clipboard

🚄 FASTJSON2 is a Java JSON library with excellent performance.

Results 392 fastjson2 issues
Sort by recently updated
recently updated
newest added

这最低API level定的是否太高了,导致我只能被迫将minSdk 从20提升到26,直接影响到APP覆盖率。

question

### 问题描述 使用FastJsonHttpMessageConverter输出string输出结果多了双引号 ### 环境信息 *请填写以下信息:* - OS信息: Win11 - JDK信息: Openjdk 1.8.0_312 - 版本信息:FastJson2 2.0.6 ### 重现步骤 以下是修复办法 ```java public class FastJson2HttpMessageConverter extends FastJsonHttpMessageConverter { public FastJson2HttpMessageConverter() { super();...

bug

Bumps [checkstyle](https://github.com/checkstyle/checkstyle) from 9.2 to 10.3.2. Release notes Sourced from checkstyle's releases. checkstyle-10.3.2 https://checkstyle.org/releasenotes.html#Release_10.3.2 Bug fixes: #11736 - MissingJavadocType: Support qualified annotation names #11655 - Update google_checks.xml to have the...

dependencies

参考数据: [https://github.com/wycst/wast-jmh-test](https://github.com/wycst/wast-jmh-test) 测试使用的wast版本是0.0.3(最新版本0.0.5), fastjson2版本是2.0.6,评测的结果fastjson2完败,差距还很大(也许选的场景样本数据有针对性) 希望通过不断的超越和反超越一步一步接近极限。

bug

问题1:怎样使用fastjson2的全局配置时间格式打印是时间戳呢?而不是每个toJSONString都去设置millis。 问题2:使用了JSON.config()设置了全局默认参数后有什么方法不使用吗??我现在某些特殊的数据不需要默认配置,需要手动配置,其他的需要默认配置。

question

配置: FastJsonHttpMessageConverter converter = new FastJsonHttpMessageConverter(); FastJsonConfig config = new FastJsonConfig(); config.setDateFormat("yyyy-MM-dd HH:mm:ss"); config.setReaderFeatures(JSONReader.Feature.FieldBased, JSONReader.Feature.InitStringFieldAsEmpty, JSONReader.Feature.SupportArrayToBean); config.setWriterFeatures(JSONWriter.Feature.WriteMapNullValue, JSONWriter.Feature.WriteNulls, JSONWriter.Feature.WriteNullListAsEmpty, JSONWriter.Feature.WriteNullStringAsEmpty, JSONWriter.Feature.WriteNullBooleanAsFalse, JSONWriter.Feature.ReferenceDetection, JSONWriter.Feature.PrettyFormat); converter.setFastJsonConfig(config); converter.setDefaultCharset(StandardCharsets.UTF_8); converter.setSupportedMediaTypes(Collections.singletonList(MediaType.APPLICATION_JSON)); converters.add(0, responseBodyConverter()); 业务处理之后需要返回如下信息: {...

bug

### 问题描述 2.0.3版本出现乱码字符和异常的时候,报错java.lang.OutOfMemoryError: Java heap space ### 重现步骤 1. 使用 `JSON.parse` 方法 2. 输入 `{"bbbb":"cccc" [+D�HPndroid 10"}` 数据 3. 出现 `java.lang.OutOfMemoryError: Java heap space` 错误 ```java JSON.parse({"bbbb":"cccc" [+D�HPndroid 10"}) ```...

bug

Caused by: java.lang.ClassCastException: java.lang.Character cannot be cast to java.lang.String

bug

### 请描述您的问题 *询问有关本项目的使用和其他方面的相关问题。* ![image](https://user-images.githubusercontent.com/72912423/181450801-86d03efe-fcca-4a13-9a8a-744d2c0bb0cb.png)

question

依赖版本 jdk1.8.0_162 ``` com.alibaba fastjson 1.2.28 ``` ``` org.projectlombok lombok 1.16.22 ``` ``` com.alibaba.fastjson2 fastjson2 2.0.4 ``` DTO ``` @Data @AllArgsConstructor @NoArgsConstructor public class TestDTO { private String name; private...

bug
question
fixed