public void unregister ( ZKMBeanInfo bean ) { if ( bean == null ) return ; String path = mapBean2Path . get ( bean ) ; try { unregister ( path , bean ) ; } catch ( InstanceNotFoundException e ) { LOG . warn ( "InstanceNotFoundException during unregister usually means more than one Zookeeper server has been running in a single JVM" ) ; LOG . warn ( "InstanceNotFoundException during unregister can be safely ignored during automated tests." ) ; } catch ( JMException e ) { LOG . warn ( "Error during unregister" , e ) ; } mapBean2Path . remove ( bean ) ; mapName2Bean . remove ( bean . getName ( ) ) ; }
Unregister MBean .