Updated webclient and add readme
This commit is contained in:
parent
a8b2346b16
commit
d9444a5925
@ -3,7 +3,7 @@ package com.cubetiqs.wsclient
|
|||||||
import org.springframework.web.reactive.function.client.WebClient
|
import org.springframework.web.reactive.function.client.WebClient
|
||||||
import reactor.core.publisher.Flux
|
import reactor.core.publisher.Flux
|
||||||
|
|
||||||
class WebClientStockClient(val webClient: WebClient) : StockClient {
|
class WebClientStockClient(private val webClient: WebClient) : StockClient {
|
||||||
override fun priceFor(symbol: String): Flux<StockPrice> {
|
override fun priceFor(symbol: String): Flux<StockPrice> {
|
||||||
return webClient.get()
|
return webClient.get()
|
||||||
.uri("http://localhost:8080/stocks/{symbol}", symbol)
|
.uri("http://localhost:8080/stocks/{symbol}", symbol)
|
||||||
|
Loading…
Reference in New Issue
Block a user