原因是jersey 内置的转换器,只能做简单的类型转换如:

首先客户端提交上来的一定是String;

String ----> String/Long/Boolean 这些基本的 可以转换,但是如果你如下写:

把String---->Date类型,那么jersey内部 就会出错,报非法的请求报文,无从调试起(花了2天才明白,以后不要再犯)

可以修改为String,然后下面如果用到的地方 转换下,如下图:

jersey HTTP Status 400 - Bad Request的更多相关文章

  1. SpringMVC格式转化错误之HTTP Status [400] – [Bad Request]

    SpringMVC中,如果直接为Date类型的属性赋值,服务器有可能会报HTTP Status [400] – [Bad Request] Type Status Report Description ...

  2. SpringMVC错误,商品添加信息HTTP Status 400 – Bad Request

    记录一个自己在做商品信息显示与传递数据的时候出现的错误, HTTP Status 400 – Bad Request Type Status Report Description The server ...

  3. springMVC 文件上传 HTTP Status 400 – Bad Request

    可能原因是:multipartResolver没有配置正确 请看解决方案: <!--文件上传 id必须为multipartResolver,不然报错HTTP Status 400 – Bad R ...

  4. SSM搭项目报错:HTTP Status 400 – Bad Request

    具体报错如下: Type Status Report Description The server cannot or will not process the request due to some ...

  5. HTTP STATUS 400 – BAD REQUEST ,SPRINGMVC错误

    400大多为前台传的数据于后台接受数据不符合,注意Date数据类型最容易错. 然后需要调用实体类的空参构造方法,,注意创建了有参构造方法后,创建一个空参构造方法.

  6. HTTP Status 400 - Required request part 'file' is not present

    今天使用Spring MVC做一个文件上传的功能,在提交表单的时候出现了如下错误:

  7. jmeter接口测试 -- status==400(Bad Request)

    一.接口请求信息 二.错误的jmeter接口请求 1.请求内容 2.响应内容 三.正确的接口请求 1.看回原本的接口请求信息,company_id = null  .这里也就不能空 四.原因分析 1. ...

  8. HttpWebRequest.GetResponse() raises exception when http status code 400 (bad request) is returned

    参考: .Net HttpWebRequest.GetResponse() raises exception when http status code 400 (bad request) is re ...

  9. HTTP Status 400 - description The request sent by the client was syntactically incorrect.

    HTTP Status 400 - type Status report message description The request sent by the client was syntacti ...

随机推荐

  1. java Class.getSimpleName() 的用法

    Usage in android: private static final String TAG = DemoApplication.class.getSimpleName(); public cl ...

  2. Android ListView 几个重要属性

    Android ListView 几个重要属性http://blog.csdn.net/avenleft/article/details/7334060 android:transcriptMode= ...

  3. android:onClick="xxx"

    一般监听OnClickListener事件,我们都是通过Button button = (Button)findViewById(....); button.setOClickLisener....这 ...

  4. CentOS-5的yum源无法使用问题

    CentOS-5的yum源无法使用问题 [root@37wan ~]# yum -y install gcc Loaded plugins: fastestmirror Determining fas ...

  5. 自定义ribbon规则

    关于ribbon的知识:. 在微服务架构中,业务都会被拆分成一个独立的服务,服务与服务的通讯是基于http restful的.Spring cloud有两种服务调用方式,一种是ribbon+restT ...

  6. vue的props和$attrs

    过去我们在vue的父子组件传值的时候,我们先需要的子组件上用props注册一些属性: <template> <div> props:{{name}},{{age}} 或者 {{ ...

  7. Sql Server 优化技巧

    1.查看执行时间和cpu占用时间 set statistics time on select * from dbo.Product set statistics time off 打开你查询之后的消息 ...

  8. Shell记录-Shell脚本基础(二)

    Shell 基本运算符 算术运算符: 运算符 描述 例子 + Addition - Adds values on either side of the operator `expr $a + $b` ...

  9. TOMCAT添加管理用户认证

    添加配置文件 --原配置文件: # tail -5 /usr/local/tomcat/conf/tomcat-users.xml <user username="tomcat&quo ...

  10. [洛谷P3292] [SCOI2016]幸运数字

    洛谷题目链接:[SCOI2016]幸运数字 题目描述 A 国共有 n 座城市,这些城市由 n-1 条道路相连,使得任意两座城市可以互达,且路径唯一.每座城市都有一个幸运数字,以纪念碑的形式矗立在这座城 ...