springboot使用fastjson解决中文乱码问题 一 问题描述 二 解决办法 在fastJson的设置中fastJsonConfig.setCharset(Charset.forName("UTF-8"));其编码方式默认为UTF-8,但仍然出现乱码情况,由于SpringBoot的编码方式是跟随系统设置,因此将编码强制到Http请求和response响应中 # application.yml文件中设置如下 spring: http: encoding: force: true 三 后来