0
我目前正在嘗試使用PrAG堆棧來監控基於彈簧啓動的微服務。有2個春天啓動項目1.5.4(pom.xml中)有以下依賴配置得到的度量和轉換度量普羅米修斯服務器:使用prometheus監控彈簧啓動服務(執行器,安全啓用)
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-hateoas</artifactId>
</dependency>
<dependency>
<groupId>com.moelholm</groupId>
<artifactId>prometheus-spring-boot-starter</artifactId>
<version>1.0.1</version>
</dependency>
普羅米修斯刮CONFIGS:
scrape_configs:
- job_name: 'Test-springboot-actuator'
scrape_interval: 2s
metrics_path: '/prometheus'
static_configs:
- targets: ['localhost:8090']
- job_name: 'secondApp'
scrape_interval: 2s
basic_auth:
username: user
password: pass
metrics_path: '/prometheus'
static_configs:
- targets: ['localhost:8080']
測試項目不使用彈簧安全性,但第二個APP使用彈簧安全性。
第二個應用程序需要基本身份驗證。 Prometheus pod無法啓動,它以某種方式不讀取已在scrape_config中設置的憑據。
任何人都可以指出我正確的方向嗎?