| commit | c544bc636cd5f93d76d4f5f44e3cf86c1fbf4a87 | [log] [tgz] |
|---|---|---|
| author | Ubuntu <ickchenjunchao@gmail.com> | Wed Jul 16 14:36:44 2025 +0000 |
| committer | Ubuntu <ickchenjunchao@gmail.com> | Wed Jul 16 14:36:44 2025 +0000 |
| tree | 744ac14505f4ab175f4c8d44aebd7bf268a00f22 | |
| parent | 2b230e54b4db42fc648f3ef56d73947cd536e145 [diff] |
update license
This repository contains the Monitoring Sidecar for the ResLens project. The sidecar is designed to monitor the parent process running on the host using tools like Pyroscope and Process Exporter. It runs as a Docker container and collects profiling and process-level metrics for real-time performance monitoring.
The repository is organized as follows:
/pyroscope Dockerfile # Builds the Pyroscope server and client image connect_pyroscope.js # Script to connect Pyroscope to the parent process pyroscope-data # Directory for storing Pyroscope server data
/process-exporter Dockerfile # Builds the Process Exporter image config.yml # Configuration file for Process Exporter
/middleware Dockerfile # Builds the middleware API service server.js # Main entry point for the middleware service package.json # Node.js dependencies for the middleware service
docker-compose.yml # Orchestrates the Pyroscope and Process Exporter containers README.md # Documentation for the repository
Before you begin, ensure you have the following installed:
Use Docker Compose to build and run the monitoring sidecar:
docker-compose down
docker-compose build
docker-compose up -d
http://localhost:4040
http://localhost:9256/metrics
The Pyroscope client connects to the parent process running on the host using the connect_pyroscope.js script. It uses eBPF or other profiling methods to capture CPU and memory usage.
The Process Exporter monitors the parent process and exposes metrics in a Prometheus-compatible format. It uses a configuration file (config.yml) to specify which processes to monitor. Host Integration:
The containers share the host‘s process namespace (pid: “host”) and mount the host’s proc filesystem to access process information.
The containers run with elevated privileges (privileged: true) to access host resources. Use this setup cautiously in production environments. Ensure that only trusted users can access the exposed metrics and profiling data.