With current setup the JMXReporter would register all metrics under org.apache.sling domain. Marc Pfaff suggested that this can cause confusion as metrics registered by non Sling bundle would also show up in Sling JMX domain.
We should customize the JMX ObjectName logic to account for bundle which has registered the metrics. One approach that can be used is
- Expose the MetricService as a ServiceFactory
- Use some custom Bundle header else fallback to Bundle Symbolic name
Discussion thread on mailing list http://markmail.org/thread/sj6yvmyhgze6jn22