ricardozanini / tenkichannel

A sample application for test scenarios with Kogito Runtimes
Apache License 2.0
9 stars 8 forks source link

Add the possibility to have only one of the external weather services being called in the loadbalance #11

Open ricardozanini opened 4 years ago

ricardozanini commented 4 years ago

Right now, an user should have API keys for OpenWeather and Yahoo for the weather-api-gateway service to work:

mvn clean package quarkus:dev 
-Dorg.tenkichannel.weather.api.gateway.openweathermap.api_key= 
-Dorg.tenkichannel.weather.api.gateway.yahooweather.id= 
-Dorg.tenkichannel.weather.api.gateway.yahooweather.consumerKey= 
-Dorg.tenkichannel.weather.api.gateway.yahooweather.consumerSecret=

Would be simpler if only one of them would be required. This needs a change on: https://github.com/ricardozanini/tenkichannel/blob/master/weather-api-gateway/src/main/java/org/tenkichannel/weather/api/gateway/routes/WeatherGatewayRoute.java#L44

To only call the configured route instead.