当前位置:网站首页>使用postman调接口报Content type ‘text/plain;charset=UTF-8‘ not supported
使用postman调接口报Content type ‘text/plain;charset=UTF-8‘ not supported
2022-07-30 17:54:00 【Charter1】
POSTMAN报错信息:
{
"msg": "Content type 'text/plain;charset=UTF-8' not supported",
"code": 500
}系统后台报错信息:
org.springframework.web.HttpMediaTypeNotSupportedException: Content type 'text/plain;charset=UTF-8' not supported
at org.springframework.web.servlet.mvc.method.annotation.AbstractMessageConverterMethodArgumentResolver.readWithMessageConverters(AbstractMessageConverterMethodArgumentResolver.java:224)
at org.springframework.web.servlet.mvc.method.annotation.RequestResponseBodyMethodProcessor.readWithMessageConverters(RequestResponseBodyMethodProcessor.java:157)
at org.springframework.web.servlet.mvc.method.annotation.RequestResponseBodyMethodProcessor.resolveArgument(RequestResponseBodyMethodProcessor.java:130)
at org.springframework.web.method.support.HandlerMethodArgumentResolverComposite.resolveArgument(HandlerMethodArgumentResolverComposite.java:126)
at org.springframework.web.method.support.InvocableHandlerMethod.getMethodArgumentValues(InvocableHandlerMethod.java:166)
at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:134)
at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:102)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:895)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:800)
at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1038)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:942)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1005)
at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:908)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:660)
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:882)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
解决办法:
疏忽大意了,需要在postman中切换下数据类型。
边栏推荐
猜你喜欢

952. 按公因数计算最大组件大小 : 枚举质因数 + 并查集运用题

网络基础(二)-Web服务器-简介——WampServer集成服务器软件之Apache+MySQL软件安装流程 & netstat -an之检测计算机的端口是否占用

windwons 下GPU环境和pytorch安装

这玩意儿都能优化?果然是细节都在魔鬼里。

DevEco Studio3.0下载失败,提示An unknown error occurred

C陷阱与缺陷 第7章 可移植性缺陷 7.5 移位运算符

ESP8266-Arduino编程实例-DS18B20温度传感器驱动

高性能短链设计

首发!阿里技术大牛最新耗时半个月整理出最全MySQL性能优化和高可用架构技术宝典,直接封神!

Kettle(二):连接SQL Server数据库
随机推荐
windwons 下GPU环境和pytorch安装
SQL存储过程详解
基础架构之Mongo
MySQL【单行函数】
JVM诊断命令jcmd介绍
Servo System of Hydraulic Steering Gear Based on Fuzzy PID
What is industrial radiography equipment?
Analysis and Simulation of Short Circuit Fault in Power System Based on MATLAB
Informatics Olympiad 1915: [01NOIP Popularization Group] Greatest Common Divisor and Least Common Multiple | Luogu P1029 [NOIP2001 Popularization Group] The problem of the greatest common divisor and
【HMS core】【FAQ】HMS Toolkit典型问题合集1
How Google earth engine realizes the arrangement and selection of our time list
FastJson反序列化漏洞(复现)
[Solved] The problem that Unity Hub fails to obtain a license or does not respond and cannot develop
软件测试13年从业经验的前辈,总结的5条测试就业建议....
5分钟搞懂MySQL - 行转列
LayaBox---TypeScript---类型兼容性
C陷阱与缺陷 第6章 预处理器 6.3 宏并不是语句
基于亚马逊云科技无服务器服务快速搭建电商平台——性能篇
数据库系统原理与应用教程(066)—— MySQL 练习题:操作题 71-81(十):连接查询
【Cloud Store Announcement】Notice of Help Center Update on July 30