code: public static CompositeMonitor<?> newObjectMonitor(String id, Object obj) {
      final TagList tags = getMonitorTags(obj);
  
      List<Monitor<?>> monitors = new ArrayList<>();
      addMonitors(monitors, id, tags, obj);
  
      final Class<?> c = obj.getClass();
      final String objectId = (id == null) ? DEFAULT_ID : id;
      return new BasicCompositeMonitor(newObjectConfig(c, objectId, tags), monitors);
    }
docs: Helper function to easily create a composite for all monitor fields and
  annotated attributes of a given object.
  
  @param id  a unique id associated with this particular instance of the
  object. If multiple objects of the same class are registered
  they will have the same config and conflict unless the id
  values are distinct.
  @param obj object to search for monitors on. All fields of type
  {@link Monitor} and fields/methods with a
  {@link com.netflix.servo.annotations.Monitor} annotation
  will be extracted and returned using
  {@link CompositeMonitor#getMonitors()}.
  @return composite monitor based on the fields of the class