The Metrics tab shows the following view containing three links:
The first link accesses the following endpoint in the io.packt.sample.metric.MetricController class:
@Path("timed")@Timed(name = "timed-request")@GET@Produces(MediaType.TEXT_PLAIN)public String timedRequest() { long start = System.currentTimeMillis(); // Demo, not production style int wait = new Random().nextInt(1000); try { Thread.sleep(wait); } catch (InterruptedException e) { // Demo e.printStackTrace(); } long end = System.currentTimeMillis(); long delay = end - start; doIncrement(); long count = getCustomerCount(); return String.format("MetricController#timedRequest, ...