Package com.linkedin.d2.discovery.stores.zk

Examples of com.linkedin.d2.discovery.stores.zk.ZooKeeper


    {
      callback.get(10, TimeUnit.SECONDS);
    }
    catch (Exception e)
    {
      throw new PropertyStoreException(e);
    }
  }
View Full Code Here


    {
      callback.get(10, TimeUnit.SECONDS);
    }
    catch (Exception e)
    {
      throw new PropertyStoreException(e);
    }
  }
View Full Code Here

    {
      callback.get(10, TimeUnit.SECONDS);
    }
    catch (Exception e)
    {
      throw new PropertyStoreException(e);
    }
  }
View Full Code Here

    {
      callback.get(10, TimeUnit.SECONDS);
    }
    catch (Exception e)
    {
      throw new PropertyStoreException(e);
    }
  }
View Full Code Here

    {
      callback.get(10, TimeUnit.SECONDS);
    }
    catch (Exception e)
    {
      throw new PropertyStoreException(e);
    }
  }
View Full Code Here

                   boolean useDeltaWrite,
                   int maxOutstandingWrites)
  {
    _retryLimit = retryLimit;
    // use retry zkConnection
    _zkConnection = new ZKConnection(zkHosts, sessionTimeout, _retryLimit, false, null, 0);
    _basePath = basePath;
    _timeout = timeout;
    _clusterServiceConfigurations = Arrays.asList(clusterServiceConfigurations, extraClusterServiceConfigurations);
    _clusterDefaults = clusterDefaults;
    _serviceDefaults = serviceDefaults;
View Full Code Here

  }

  @Override
  public void getServiceNames(final Callback<List<String>> callback)
  {
    final ZooKeeper zk = _connection.getZooKeeper();
    final String path = ZKFSUtil.servicePath(_basePath);
    zk.getChildren(path, false, new AsyncCallback.Children2Callback()
    {
      @Override
      public void processResult(int rc, String path, Object ctx, List<String> children, Stat stat)
      {
        KeeperException.Code code = KeeperException.Code.get(rc);
View Full Code Here

  }

  @Override
  public void getClusterNames(final Callback<List<String>> callback)
  {
    final ZooKeeper zk = _connection.getZooKeeper();
    final String path = ZKFSUtil.clusterPath(_basePath);
    zk.getChildren(path, false, new AsyncCallback.Children2Callback()
    {
      @Override
      public void processResult(int rc, String path, Object ctx, List<String> children, Stat stat)
      {
        KeeperException.Code code = KeeperException.Code.get(rc);
View Full Code Here

  }

  public static List<String> getServicesGroups (ZKConnection zkclient, String basePath) throws Exception
  {
    List<String> servicesGroups = new ArrayList<String>();
    ZooKeeper zook = zkclient.getZooKeeper();

    List<String> children = zook.getChildren(basePath,false);

    for (String child : children)
    {
      if (! child.equalsIgnoreCase("clusters") && ! child.equalsIgnoreCase("uris"))
      {
View Full Code Here

          latch.countDown();
        }
      }
    };

    ZooKeeper zk = _zkclient.getZooKeeper();
    for (String path : expectedVersionMap.keySet())
    {
      zk.exists(path, false, statCallback, null);
    }

    // Wait for expectedVersionMap to be populated.
    if (!latch.await(5, TimeUnit.SECONDS))
    {
View Full Code Here

TOP

Related Classes of com.linkedin.d2.discovery.stores.zk.ZooKeeper

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.