Java spring-cloud-feign@Requestparam-name包含符号[]
我尝试创建一个查询Java spring-cloud-feign@Requestparam-name包含符号[],java,spring,spring-cloud-feign,Java,Spring,Spring Cloud Feign,我尝试创建一个查询 @FeignClient(name = "geohelper", url = "http://geohelper.info/api/v1") public interface GeohelperAPI { @GetMapping(path = "/regions", consumes = "application/json") GeohelperResponse getRegion(@RequestParam(name = "apiKey") String apiKey,
@FeignClient(name = "geohelper", url = "http://geohelper.info/api/v1")
public interface GeohelperAPI {
@GetMapping(path = "/regions", consumes = "application/json")
GeohelperResponse getRegion(@RequestParam(name = "apiKey") String apiKey,
@RequestParam(name = "locale[lang]") String localeRu,
@RequestParam(name = "filter[name]") String region);
}
我的requestparams的名称包含符号[和]
创建的请求看起来像
apiKey=somekeysymbols和区域设置%5Blang%5D=%7BLANGE%5Blang%5D%7D和筛选器%5Bname%5D=%7Bfilter%5Bname%5D%7D
在值中有{locale[lang]}
和{filter[name]}
而不是“rightValueString”
这是虫子吗?我怎样才能逃避这个[?我也有同样的问题。你能解决吗?不,我不能解决