Skip to content

Commit

Permalink
feature/#173 : prometheus 세팅
Browse files Browse the repository at this point in the history
Signed-off-by: EunJiJung <[email protected]>
  • Loading branch information
bianbbc87 committed Nov 27, 2024
1 parent 1f87319 commit fb24a47
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
21 changes: 21 additions & 0 deletions config/prometheus.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
global:
scrape_interval: 15s

scrape_configs:
- job_name: 'api-server'
metrics_path: '/actuator/prometheus'
static_configs:
- targets: ['127.0.0.1:8080']

- job_name: 'bank'
metrics_path: '/actuator/prometheus'
static_configs:
- targets: ['127.0.0.1:8081']

- job_name: 'prometheus'
static_configs:
- targets: ['localhost:9090']

- job_name: 'jmeter'
static_configs:
- targets: ['127.0.0.1:9270'] # JMeter 플러그인을 통한 데이터 수집
6 changes: 5 additions & 1 deletion src/main/java/com/daon/onjung/core/constant/Constants.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ public class Constants {
"/api-docs.html",
"/api-docs/**",
"/swagger-ui/**",
"/v3/**"
"/v3/**",

// prometheus
"/actuator/",
"/actuator/**"
);

/**
Expand Down

0 comments on commit fb24a47

Please sign in to comment.