spring-cloud / spring-cloud/spring-cloud-openfeign
Add support for placeholders to Feign spring-mvc annotations of headers field
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 1.3k
- Forks
- 838
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 13
Description
Hi, I saw there is an issue spring-cloud/spring-cloud-netflix#894 which add support for placeholders of value field.
But other field such as "headers" still not support placeholder.
Since sometimes we need set Authentication header, it is awesome if the value could be loaded from properties file.
@FeignClient("foo")
public interface FooClient{
@RequestMapping(value = "${my.special.placeholder}",
method = RequestMethod.GET,
headers = "${my.token}"
ResponseEntity getSomeData(s);
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how Feign spring-mvc annotations currently resolve placeholders for the value field, then compare that path with handling of the headers field. Confirm the expected syntax from the issue example and verify that header placeholders load from application properties without breaking existing header behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, spring
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100