The goal of this project is to develop a system in Go that takes a postal code as input, identifies the city, and returns the current weather (temperature in Celsius, Fahrenheit, and Kelvin), using Open Telemetry and Zipkin to trace the requests.
- Programming Language: Go
- External APIs: viaCEP and WeatherAPI
- Observability: Open Telemetry and Zipkin
- Containerization: Docker
- Go 1.16+ installed
- Docker installed (for running the project via Docker)
- An internet connection to access external APIs (viaCEP and WeatherAPI)
- Service Input:
- WEATHER_SERVICE_URL = http://service-orchestration:8081/
- SERVICE_NAME = service-input
- OTEL_COLLECTOR_ADDR = otel-collector:4317
- Service Orchestration:
- WEATHER_API_KEY = {YOUR_API_KEY} WeatherAPI
- SERVICE_NAME = service-orchestration
- OTEL_COLLECTOR_ADDR = otel-collector:4317
- Run the following command to start the application:
docker-compose up
- Make a request to the service-input:
curl --request POST --url 'http://localhost:8080' -H "Content-Type: application/json" -d '{"cep" : "01001000"}'
To access the Zipkin dashboard, open your browser and go to the following address:
http://localhost:9411