https://github.com/sandysanthosh/feign-client-microservices
Easy Integration with multiple Microservice's using Feign Client
https://github.com/sandysanthosh/feign-client-microservices
Last synced: 5 months ago
JSON representation
Easy Integration with multiple Microservice's using Feign Client
- Host: GitHub
- URL: https://github.com/sandysanthosh/feign-client-microservices
- Owner: sandysanthosh
- License: apache-2.0
- Created: 2020-08-24T17:55:28.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-10-02T07:20:51.000Z (over 5 years ago)
- Last Synced: 2025-02-28T20:57:54.057Z (11 months ago)
- Homepage:
- Size: 6.84 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# FeignRest-Microservices
#### Pom.xml:
```
org.springframework.cloud
spring-cloud-starter-feign
1.4.4.RELEASE
```
#### Annotations.java:
@SpringBootApplication
@EnableFeignClients
#### SpringCloud/RestClients/CouponClient.java:
```
@FeignClient("stores")
public interface StoreClient {
@RequestMapping(method = RequestMethod.GET, value = "/stores")
List getStores();
@RequestMapping(method = RequestMethod.GET, value = "/stores")
Page getStores(Pageable pageable);
@RequestMapping(method = RequestMethod.POST, value = "/stores/{storeId}", consumes = "application/json")
Store update(@PathVariable("storeId") Long storeId, Store store);
}
```
#### Application.yml:
```
feign:
client:
config:
default:
connectTimeout: 5000
readTimeout: 5000
loggerLevel: basic
```