We can connect via JMX and interrogate them for information. There are multiple tools available, so why not start with JConsole, the one that comes with the JDK already on our system?
In one shell, we need to launch our application as follows:
$ ./gradlew bootRun ...
Somewhere in this console output, there is a debug message containing JMX consoles can connect to service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi. Let's save this value so that we can use it further down in this section.
From another shell, launch JConsole as follows:
A subwindow should pop up. Select Remote Process and enter the address we just found, as shown in the following screenshot:
With the connection string entered, ...