Code for the talk from Scalar 2025. The video is available here: https://www.youtube.com/watch?v=Vy-0LL0REnI
- Start the Kafka broker & associated services using
kafka/docker-compose.yml. After some time, the control center should be available athttp://localhost:9021. - Start the Posgres database & Grafana LGTM stack (monitoring, logging, tracing) using
docker-compose.yml. Once again, after some time, the Grafana dashboard should be available athttp://localhost:3000. You can login withadmin/admin. - Start the backend using
./backend-start.sh. This should create the tables and start the API. OpenAPI documentation should be available athttp://localhost:8080/api/v1/docs/. - The travel page which is shown in the talk uses two external services (which are part of the distributed trace).
From an IDE, start the
scalar.directdemo.services.PickRandomServiceandscalar.directdemo.services.TravelModeServiceapps. - You can now try calling the trip service via OpenAPI. Once you do that, you can check in the Grafana dashboard if the trace shows up - after a couple of seconds. Go to "explore" from the "hamburger" menu, then switch from Prometheus to Tempo, switch to "Search" and take a look at the available traces.
- Finally, copy
ui/.env.exampleasui/.envand run./frontend-start.sh. This should open your default browser withhttp://localhost:8081/. Go tohttp://localhost:8081/tripand click the button - the backend service should be called. - You might also open Kafka's control center, choose the
tripstopic, then the "Messages" tab, to view the result of the background streaming.