@Override public SolrInfoMBean put(String key,SolrInfoMBean infoBean){
  if (server != null && infoBean != null) {
    try {
      ObjectName name=getObjectName(key,infoBean);
      if (server.isRegistered(name))       server.unregisterMBean(name);
      SolrDynamicMBean mbean=new SolrDynamicMBean(coreHashCode,infoBean,useCachedStatsBetweenGetMBeanInfoCalls);
      server.registerMBean(mbean,name);
    }
 catch (    Exception e) {
      log.warn("Failed to register info bean: " + key,e);
    }
  }
  return super.put(key,infoBean);
}

@ Override public SolrInfoMBean put ( String key , SolrInfoMBean infoBean ) { if ( server != null && infoBean != null ) { try { ObjectName name = getObjectName ( key , infoBean ) ; if ( server . isRegistered ( name ) ) server . unregisterMBean ( name ) ; SolrDynamicMBean mbean = new SolrDynamicMBean ( coreHashCode , infoBean , useCachedStatsBetweenGetMBeanInfoCalls ) ; server . registerMBean ( mbean , name ) ; } catch ( Exception e ) { log . warn ( "Failed to register info bean: " + key , e ) ; } } return super . put ( key , infoBean ) ; }
adds the solrinfombean to the map and registers the given solrinfombean instance with the mbeanserver defined for this core . if a solrinfombean is already registered with the mbeanserver then it is unregistered and then re - registered .
