Skip to content

$ not support in the name of query parameters #1036

@pvreeburg

Description

@pvreeburg

I encountered an issue with the processing of query parameters that contain a $ in their name. These apparently aren't processed as expressions but as literals.

I'm currently using FeignJaxRs2 versions '10.2.3'.

Example :

public interface TestClient {
    @GET
    @Path("/test")
    String apiCall(@QueryParam("$fields") String value);
}

public void test_with_empty_name() {
    String result = testClient.apiCall("field1,field2");
}

results in the URI :

.../test?$fields={$fields}

instead of:

.../test?$fields=field1,field2

It appears to go wrong in the class feign.template.Expressions.
The regex used to validate the name of the queryparameter doesn't currently allow $.

Metadata

Metadata

Assignees

Labels

bugUnexpected or incorrect behavior

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions