anchor.diff:  
   [[production-ready-metrics-web-flux]]
   ==== Spring WebFlux Metrics
  -Auto-configuration enables the instrumentation of all requests handled by WebFlux controllers and functional handlers.
  -When `management.metrics.web.server.request.autotime.enabled` is `true`, this instrumentation occurs for all requests.
  -Alternatively, when set to `false`, you can enable instrumentation by adding `@Timed` to a request-handling method in the same way the Spring MVC example above.
  -
  -By default, metrics are generated with the name `http.server.requests`.
  -You can customize the name by setting the configprop:management.metrics.web.server.request.metric-name[] property.
  -
  -By default, WebFlux-related metrics are tagged with the following information:
  +Auto-configuration enables the instrumentation of all requests handled by Spring WebFlux controllers and functional handlers.
  +By default, metrics are generated with the name, `http.server.requests`.
  +The name can be customized by setting the configprop:management.metrics.web.server.request.metric-name[] property.
  +
  +`@Timed` annotations are supported on `@Controller` classes and `@RequestMapping` methods (see <<production-ready-metrics-timed-annotation>> for details).
  +If you don't want to record metrics for all Spring WebFlux requests, you can set configprop:management.metrics.web.server.request.autotime.enabled[] to `false` and exclusively use `@Timed` annotations instead.
  +
  +By default, WebFlux related metrics are tagged with the following information:
   
   |===
   | Tag | Description
  
positive.code: 
  
  
  [[production-ready-metrics-kafka]]
  ==== Kafka Metrics
  Auto-configuration will register a `MicrometerConsumerListener` and `MicrometerProducerListener` for the auto-configured consumer factory and producer factory respectively.
  
negative.code: 	      connectionpool:
  	        enabled: false
  ----
  
  
  
  [[production-ready-metrics-timed-annotation]]
  ==== @Timed Annotation Support
  The `@Timed` annotation from the `io.micrometer.core.annotation` package can be used with several of the supported technologies listed above.
  If supported, the annotation can be used either at the class-level or the method-level.
  
  For example, the following code shows how the annotation can be used to instrument all request mappings in a `@RestController`:
  
  [source,java,pending-extract=true,indent=0]
  ----
  	@RestController
  	@Timed
  	public class MyController {
  
  		@GetMapping("/api/addresses")
  		public List<Person> listAddress() { ... }
  
  		@GetMapping("/api/people")
  		public List<Person> listPeople() { ... }
  
  	}
  ----
  
  If you only want to instrument a single mapping, you can use the annotation on the method instead of the class:
  
  [source,java,pending-extract=true,indent=0]
  ----
  	@RestController
  	public class MyController {
  
  		@GetMapping("/api/addresses")
  		public List<Person> listAddress() { ... }
  
  		@GetMapping("/api/people")
  		@Timed
  		public List<Person> listPeople() { ... }
  
  	}
  ----
  
  You can also combine class-level and method-level annotations if you want to change timing details for a specific method:
  
  [source,java,pending-extract=true,indent=0]
  ----
  	@RestController
  	@Timed
  	public class MyController {
  
  		@GetMapping("/api/addresses")
  		public List<Person> listPeople() { ... }
  
  		@GetMapping("/api/people")
  		@Timed(extraTags = { "region", "us-east-1" })
  		@Timed(value = "all.people", longTask = true)
  		public List<Person> listPeople() { ... }
  
  	}
  ----
  
  NOTE: A `@Timed` annotation with `longTask = true` will enable a long task timer for the method.
  Long task timers require a separate metric name, and can be stacked with a short task timer.
  
  
  
  