multi-services

module
v0.0.0-...-e0c33b1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 18, 2025 License: Apache-2.0

README

Multi Services Example

This is a simple example of how instrumenting multiple services.

There are 2 services in this example:

  • front-svc => the front service receiving requests from the client
  • back-svc => the service that is being called by front-svc (hence named back)

Architecture Diagram

All traces will be collected in Jaeger, and metrics will be collected in Prometheus.

Observability Components

This example demonstrates a complete observability setup with:

  • Distributed Tracing: Using Jaeger to collect and visualize distributed traces across services
  • Metrics: Using Prometheus to collect and monitor metrics from both services
  • Visualization:
    • Jaeger UI for trace visualization (http://localhost:16686)
    • Prometheus UI for metrics querying and visualization (http://localhost:9090)

How to Run

Make sure to have Docker & Docker Compose installed in your system. After that run this command:

> make run

If the command runs successfully (it will take a moment), you will see something like this in the terminal:

back-svc_1   | 2022/07/23 01:49:29 back service is listening on :8091
front-svc_1  | 2022/07/23 01:49:26 front service is listening on :8090
...
multi-services_client_1 exited with code 0

Open your browser and access http://localhost:16686 to access the Jaeger UI.

You should see some traces available already in the UI.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL