Prometheus Integration
Overview
Prometheus serves as the primary metrics collection and storage system for Gluesync. This integration provides real-time monitoring capabilities with configurable retention and storage options.
For a complete list of available metrics and their descriptions, see the Metrics Reference. |
Default Configuration
Gluesync provides a pre-configured Prometheus setup through Docker Compose:
services:
prometheus:
image: prom/prometheus
restart: 'unless-stopped'
volumes:
- ./prometheus-gs2.yml:/etc/prometheus/prometheus.yml
- ./data:/prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.retention.size=10GB'
- '--storage.tsdb.retention.time=7d'
ports:
- 9090:9090
Configuration Options
Core Settings
Setting | Default | Description |
---|---|---|
retention.size |
10GB |
Maximum storage size for metrics data. Increase for larger deployments or longer history. |
retention.time |
7d |
Duration to retain metrics. Adjust based on your compliance and analysis needs. |
scrape_interval |
15s |
Frequency of metrics collection. This directly affects how often Core Hub updates its metrics. |
ports |
9090 |
Prometheus web interface and API port. Can be modified for security or port conflicts. |
The
Choose an interval that balances your monitoring needs with system performance. |
Security Considerations
HTTPS Configuration
To enable HTTPS for secure metrics collection:
command:
- '--web.config.file=/etc/prometheus/web-config.yml'
volumes:
- ./web-config.yml:/etc/prometheus/web-config.yml
- ./certificates:/etc/prometheus/certs
Example web-config.yml
:
tls_server_config:
cert_file: /etc/prometheus/certs/prometheus.crt
key_file: /etc/prometheus/certs/prometheus.key
Available Metrics
For a complete list of available metrics and their descriptions, see the Metrics Reference.
Performance Tuning
Storage Optimization
For high-throughput environments:
command:
- '--storage.tsdb.retention.size=200GB' # Increased storage
- '--storage.tsdb.retention.time=30d' # Extended retention
- '--storage.tsdb.wal-compression' # Compress write-ahead log
- '--query.max-samples=100000000' # Larger query limit
Scrape Configuration
Adjust scrape intervals based on your needs:
global:
scrape_interval: 15s # Default collection interval
scrape_timeout: 10s # Timeout for each scrape
evaluation_interval: 15s # Rule evaluation interval
For production environments, consider increasing scrape_interval to reduce system load, or decreasing it for more granular metrics.
|