Search code examples
javaspring-bootapache-camelweather-apiopenweathermap

Getting started with apache camel-weather library


I want to attach the camel-weather library to my project. I'm using spring boot in my application. I cannot find any examples and tutorials related to this lib.

Documentation is too short to me and I don't now how to start... :( Doc is under: http://camel.apache.org/weather.html.

Could anybody help me with get response from server? I created my API KEY on http://openweathermap.org/appid but I don't now how get response using this library in java. I also looked at the maven dependency classes and found some classes, Producers and so on, but how to get the response?


Solution

  • The camel-weather module is designed to work with the Apache Camel library. You need to familiarise yourself with it before you can use this particular module. Now ask yourself if that is indeed what you need?

    Apache Camel is a sophisticated message bus that implements numerous "enterprise integration patterns". This module was probably written as an example on how to get started on writing one. It probably has no real world use in a use case where Camel is the library of choice :)

    If you just want to pull some weather forecast data and display it on a web page, just use a common HTTP client implementation and simply query the Open Weather Map API directly.