JIM Data in Grafana
Explore JIM trace data in Grafana via the Summary, Audit, or Deep Dive workflows.
Requires Grafana access, a Jaeger data source and collected JIM traces.
Introduction#
The Java Instrumentation and Monitoring (JIM) agent monitors the Java applications of clients. JIM agent gives the execution time of the methods in the application, method parameter details, stack trace, exceptions occurred, etc.
JIM agent and client applications run on the target server. There may be multiple client applications running on the target server. One instance of the JIM agent monitors one instance of the application.
The JIM agent sends code-level analysis details to the Jaeger collector in the form of gRPC protocol buffers. Authorized administrators set JIM mode in Control Center through Java Intrusive Agent Setting; the agent receives the approved configuration from Control Center.
The Jaeger collector processes the data it receives from the JIM agent and stores the data in the OpenSearch database. In a microservices framework, where various microservices communicate with each other, you can capture the transaction flow using the JIM agent. Grafana is for visualization. You can view the details on the Grafana UI.
Jaeger Collector, OpenSearch, Jaeger Query API, and Grafana are part of the HEAL installer.
Viewing JIM data in Grafana#
You can instrument an application using the JIM agent. You can see service names corresponding to the application in Grafana. You can identify the application based on the service name. These services can be front-end, back-end, or query services. In Grafana, a service represents an application. You can view traces as per the query you execute. A trace consists of multiple spans. A span represents a captured operation; depending on the instrumentation, that operation can be a method, request, query, or client call. Each row in the trace view represents one captured span. Grafana displays spans in waterfall fashion.
Click Explore.

Select the Jaeger data source you created to view the traces and spans.

Click Search.

Select a service from the Service box.

Select an operation (method call) from the Operation box.

You can specify the query filter in the Tags box. You can select values in the Advanced Options section. Whatever value you provide in the Min Duration box, Grafana displays traces having durations greater than or equal to that value. Whatever value you provide in the Max Duration box, Grafana displays traces having durations less than or equal to that value. Provide the count of traces in the Limit box which you need to see in the query result.

Click 'Run query' in the top right corner. You can view the traces corresponding to the query execution.

You can select the time period from the top right corner to view the results as per the time interval you select.

Click on an ID in the Trace ID column. Grafana displays the Trace View in the right pane. Grafana displays all the spans corresponding to the trace and the method execution time for each of the spans. Grafana represents a service in a unique color in the trace. The waterfall positions each span relative to the trace start. Child and sibling spans can nest, overlap, or run concurrently, so do not calculate a span start by adding the prior row's duration.








Grafana displays three sections for each span – Tags, Processes, and Logs. The logs section displays the stack trace for the method execution. The tags section displays various attributes related to the method, like thread counts, name of the method getting executed, status of the transaction, CPU time, System time, mode of the JIM agent, etc.


Thread CPU time fields record the thread-CPU counters captured at operation entry and exit. Use their difference only according to the field semantics and units documented for the installed JIM agent version; do not assume clock ticks or a CPU-capacity percentage.
thread.cpu.time.entry and thread.cpu.time.exit are the captured entry and exit counter values.
The system-time field names and displayed units can vary by installed JIM and dashboard version. Confirm the unit shown by the current field definition before comparing values.
(sys.time.millis.exit - sys.time.millis.entry) is the elapsed system time.
(thread.cpu.time.exit - thread.cpu.time.entry) is the consumed CPU time.
If the elapsed system time and consumed CPU time are reasonably proportional, then the transaction is normal. An authorized administrator can set the JIM agent to Auto or Verbose through Java Intrusive Agent Setting. The status of a transaction can be OK, SLOW, or ERROR. Verbose mode adds load onto the server since it captures all types of transactions. The JIM agent captures stack traces for slow, error, and success spans in verbose mode. The JIM agent captures stack traces for slow and error spans in auto mode.













JIM Dashboards#
Below are the different types of JIM dashboards: