OpenFeign / OpenFeign/feign

Take ProxyMethod's "argv" into RequestTemplate

Open
#2,445 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
9.8k
Forks
1.9k
Avg merge
1d 2h
Merged PRs (30d)
41

Description

Hello, BIG_OLD, :)

i want to visit the original argv of the service func, which is decribe by @FeignClient, @RequestMapping

it can help me such like calculting a new Host Address

maybe i can parse from the RequestTemplate too, but i think it's boring and complex.

so, i hope that, you can take it into RequestTemplate as a field when you create it. (i want do it myself, but i can, cause some class is final class, and also not exists a direct position to handle it).

And then, i can use it with MethodMetadata for more magical operation.

the position i found : SynchronousMethodHandler.java - Line 65.

RequestTemplate template = buildTemplateFromArgs.create(argv); 

go into the #create(argv), it just put the argv's item to what it want, and never save it.

that's all. Thank you. Dear BIG_OLD.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at SynchronousMethodHandler.java around the RequestTemplate template = buildTemplateFromArgs.create(argv) call, then trace BuildTemplateByResolvingArgs and RequestTemplate creation to understand where argv is discarded. Done means the original service arguments are available through RequestTemplate alongside the existing request data without breaking argument expansion.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
api
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.