コード例 #1
0
    public synchronized HttpRemoteStore get() {
      if (remoteStore == null) {
        HttpClient httpClient = injector.getInstance(httpClientKey);
        StoreConfig storeConfig = injector.getInstance(storeConfigKey);

        remoteStore =
            new HttpRemoteStore(
                name, nodeInfo, serviceSelector, storeConfig, httpClient, monitor, mbeanExporter);
        remoteStore.start();
      }

      return remoteStore;
    }
コード例 #2
0
 @PreDestroy
 public synchronized void shutdown() {
   if (remoteStore != null) {
     remoteStore.shutdown();
   }
 }