Annotation Interface JmxAttributeField


@Retention(RUNTIME) @Target(FIELD) public @interface JmxAttributeField

This identifies which fields you want to expose via JMX via reflection. If the field is not public then it will try to open the accessibility on the field. Instead of annotating the fields, you can annotate your getXxx(), setXxx(), and isXxx() methods with JmxAttributeMethod.

@JmxAttributeField(description = "Number of times our cache was hit")
private int cacheHitCount;
Author:
graywatson
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Description of the attribute for jconsole.
    boolean
    Set to false if the field should not be read through JMX.
    boolean
    Set to true if the field can be written by JMX.
  • Element Details

    • description

      String description
      Description of the attribute for jconsole. Default is something like: "someField attribute".
      Default:
      ""
    • isReadible

      boolean isReadible
      Set to false if the field should not be read through JMX. Default is true.
      Default:
      true
    • isWritable

      boolean isWritable
      Set to true if the field can be written by JMX. Default is false.
      Default:
      false