我正在使用我的java代码中的REST Web服务。通过java.net.URLEncoder中URL编码后的400次错误请求
之前,请调用REST Web服务,我编码我的查询参数但是,要求越来越400错误的请求例外
编码之前的URL失败:host?limit=200&filter=published ge "2017-12-15T16:50:34.034Z" and (action.objectType eq "core.user_group_member.user_add" or action.objectType eq "core.user_group_member.user_remove")
网址解码后:%3Flimit%3D200%26filter%3Dpublished%20ge%20%222017-12-15T16%3A50%3A34.034Z%22%20and%20%28action.objectType%20eq%20%22core.user_group_member.user_add%22%20or%20action.objectType%20eq%20%22core.user_group_member.user_remove%22%29
我试着从邮差休息客户端工具那里也没有编码的URL工作和编码的URL失败,400错误的请求错误。
您需要对值进行网址编码,而不是整个网址。 – Kayaman
是的,我只编码查询字符串?字符 –
是的,我说的是数值,而不是整个查询字符串。 – Kayaman