class HubRegistry implements PartitionListener {

   public void offline(String hubId, String hubBridge) {
      HubState state = hubs.get(hubId);
      if(state == null) {
         logger.debug("Received disconnected for untracked hub [{}]", hubId);
         disconnected(hubId);
      }
      else if(state.offline(hubBridge, clock.millis() - offlineTimeoutMs) && hubs.remove(hubId, state)) {
         logger.debug("Hub disconnected [{}]", hubId);
         metrics.onDisconnected();
         disconnected(hubId);
      }
      else {
         logger.debug("Hub reconnected [{}]", hubId);
      }
   }

   @Inject public  HubRegistry(
         Clock clock,
         HubDAO hubDao,
         Partitioner partitioner,
         PlatformMessageBus platformBus,
         HubRegistryConfig config,
         PlacePopulationCacheManager populationCacheMgr
   );

}