Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

对集合参数的解析不支持 #39

Open
4017147 opened this issue Nov 27, 2024 · 1 comment
Open

对集合参数的解析不支持 #39

4017147 opened this issue Nov 27, 2024 · 1 comment

Comments

@4017147
Copy link

4017147 commented Nov 27, 2024

基础信息

操作系统:xxx 如:Ubuntu
Juggle版本:x.x.x 如:1.0.0
部署方式:xxx 如:Docker

问题描述

protected void buildRequestParams(HttpUriRequestBase httpRequest, Request request) {
if (request.getRequestParams() != null) {
String jsonParam = null;
try {
jsonParam = JsonSerializeHelper.serialize(request.getRequestParams());
} catch (JsonProcessingException e) {
throw new RuntimeException(e);
}
StringEntity stringEntity = new StringEntity(jsonParam, ContentType.APPLICATION_JSON);
httpRequest.setEntity(stringEntity);
}
}

request.getRequestParams() 的参数未对集合参数特殊处理、对值没有转换成集合对象、导致下层接口获取参数失败(调用的下层接口是 json、body、参数当中有一个集合参数、这个集合参数没有序列化成数组)

复现步骤

错误日志或截图

@somta
Copy link
Owner

somta commented Nov 27, 2024

有具体的截图吗?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants