Skip to content

Instantly share code, notes, and snippets.

@nitishakalwadi
Created June 17, 2020 07:22
Show Gist options
  • Save nitishakalwadi/b5db5544e32ce8e8f2a3323fc4b34181 to your computer and use it in GitHub Desktop.
Save nitishakalwadi/b5db5544e32ce8e8f2a3323fc4b34181 to your computer and use it in GitHub Desktop.
Spring Boot Hikari New Relic
1. Enable hikari mbean registry in application.properties
spring.datasource.hikari.register-mbeans=true
2. Add the new relic custom instrumentation yml file in the extensions directory where new relic agent is present
name: hikari-db
version: 1.0
enabled: true
jmx:
- object_name: com.zaxxer.hikari:type=Pool (SpringBootJPAHikariCP)
metrics:
- attributes: ActiveConnections, IdleConnections, ThreadsAwaitingConnection, TotalConnections
type: simple
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment