Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable JVM metrics - prometheus #300

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
!prometheus-jmx-config.yaml
7 changes: 6 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,10 @@ ENV VERTICLE_HOME /usr/verticles
# Copy your fat jar to the container
COPY target/${VERTICLE_FILE} ${VERTICLE_HOME}/${VERTICLE_FILE}

# Add JMX exporter and config
RUN mkdir -p jmx_exporter &&\
wget -P jmx_exporter https://repo1.maven.org/maven2/io/prometheus/jmx/jmx_prometheus_javaagent/0.17.2/jmx_prometheus_javaagent-0.17.2.jar
COPY ./prometheus-jmx-config.yaml jmx_exporter/

# Expose this port locally in the container.
EXPOSE 8081
EXPOSE 8081 9991
2 changes: 2 additions & 0 deletions prometheus-jmx-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
rules:
- pattern: ".*"