Yupiik Metrics Scraper is a light tool designed to simply scrap and index metrics form Prometheus/OpenMetrics sources to ElasticSearch.
|
Important
|
Ensure to use maven >= 3.9 and Java >= 21. |
MetricsScraperConfiguration contains the application configuration.
It uses Yupiik Fusion configuration mechanism which uses system properties and environment variable to bind values on a record.
It enables to inject the configuration from system properties or environment variable.
JAVA_UTIL_LOGGING_MANAGER="io.yupiik.logging.jul.YupiikLogManager"
METRICS_SCRAPER_THREADING_CORE="8"
METRICS_SCRAPER_THREADING_MAX="32"
METRICS_SCRAPER_SCRAPERS_LENGTH="3"
METRICS_SCRAPER_SCRAPERS_0_URL="http://metrics-mock:1080/metrics"
METRICS_SCRAPER_SCRAPERS_0_SCRAPING_INTERVAL="30000"
METRICS_SCRAPER_SCRAPERS_0_TAGS="
application = testApp1
env = PROD"
METRICS_SCRAPER_SCRAPERS_1_URL="http://metrics-mock:1080/metrics2"
METRICS_SCRAPER_SCRAPERS_1_SCRAPING_INTERVAL="30000"
METRICS_SCRAPER_SCRAPERS_1_TAGS="
application = testApp2
env = ITG
"
METRICS_SCRAPER_SCRAPERS_2_URL="http://metrics-mock:1080/metrics3"
METRICS_SCRAPER_SCRAPERS_2_SCRAPING_INTERVAL="30000"
METRICS_SCRAPER_SCRAPERS_2_TAGS="
application = testApp3
env = PROD
"
METRICS_SCRAPER_ELASTICSEARCH_BASE="http://metrics-elasticsearch:9200"
METRICS_SCRAPER_ELASTICSEARCH_INDEXPREFIX="test-scraper-"
IO_YUPIIK_METRICS_SCRAPER_LEVEL="FINE"You can build the project docker image using: mvn package jib:dockerBuild [-DskipTests] (docker) or mvn package jib:build [-Dimage.registry=…] [-DskipTests] (remote registry if configured with related properties).
Comprehensive documentation is available at:
We warmly welcome contributions!
-
Fork the repository
-
Submit your enhancements via pull requests
-
Create issues