Will Feign support "/countries?{queryParamList}" Path pattern · Issue #429 · OpenFeign/feign · GitHub
Skip to content

Will Feign support "/countries?{queryParamList}" Path pattern #429

Closed

Description

@seno5979

Hi,

I know that currently feign does support @QueryMap to solve dynamic query param values.

Our system is currently using JAXRS + resteasy for REST client framework. We are planning to migrate our framework to FEIGN without making many changes on the Rest Client Interface itself (which is still using JAXRS Annotation).

I know that FEIGN also supporting JAXRS Contract, but it is not 100% backward compatible when I try to migrate from RESTEASY to FEIGN.

One of the scenario that will fail is for such feature that is using below Path pattern :

    @GET
    @Path(value = "/countries?{queryParamList}")
    Country  getCountry(@PathParam("queryParamList") String queryParamList);

It resulted as null pointer exception for pattern above.

java.lang.NullPointerException
    at feign.RequestTemplate.replaceQueryValues(RequestTemplate.java:605)
    at feign.RequestTemplate.resolve(RequestTemplate.java:210)
    at feign.ReflectiveFeign$BuildTemplateByResolvingArgs.resolve(ReflectiveFeign.java:294)
    at feign.ReflectiveFeign$BuildTemplateByResolvingArgs.create(ReflectiveFeign.java:213)
    at feign.SynchronousMethodHandler.invoke(SynchronousMethodHandler.java:72)

My really question is, Will FEIGN also support such pattern in the future ?

If yes, I can contribute my code change for pull request.

If no, Is the NullPointerException is expeted ?

Thanks.

Activity

  1. codefromthecrypt commented on Aug 7, 2016

    @codefromthecrypt
  2. added
    bugUnexpected or incorrect behavior
    on Jul 20, 2018
  3. kdavisk6 commented on Sep 24, 2018

    @kdavisk6
    Member

    Closed via #778

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    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