Examples of ZkConfiguration


Examples of net.sf.katta.util.ZkConfiguration

  public void testReconnectNode() throws Exception {
    final int GATEWAY_PORT = 2190;
    final Master master = new Master(_zk.getInteractionProtocol(), false);

    // startup node over gateway
    final ZkConfiguration gatewayConf = new ZkConfiguration();
    gatewayConf.setZKRootPath(_zk.getZkConf().getZkRootPath());
    gatewayConf.setZKServers("localhost:" + GATEWAY_PORT);
    Gateway gateway = new Gateway(GATEWAY_PORT, _zk.getServerPort());
    gateway.start();
    final ZkClient zkGatewayClient = ZkKattaUtil.startZkClient(gatewayConf, 30000);
    InteractionProtocol gatewayProtocol = new InteractionProtocol(zkGatewayClient, gatewayConf);
    FileUtil.deleteFolder(new NodeConfiguration().getShardFolder());
View Full Code Here

Examples of net.sf.katta.util.ZkConfiguration

  private static Logger LOG = Logger.getLogger(DeployUndeploySearchInLoop.class);

  public static void main(String[] args) throws Exception {
    LuceneClient luceneClient = new LuceneClient();
    ZkConfiguration zkConfig = new ZkConfiguration();
    DeployClient deployClient = new DeployClient(ZkKattaUtil.startZkClient(zkConfig, 60000), zkConfig);

    QueryParser parser = new QueryParser(Version.LUCENE_30, "field", new KeywordAnalyzer());
    Query query = parser.parse("foo: b*");

 
View Full Code Here

Examples of net.sf.katta.util.ZkConfiguration

  private final int _maxTryCount;
  protected InteractionProtocol _protocol;
  private INodeProxyManager _proxyManager;

  public Client(Class<? extends VersionedProtocol> serverClass) {
    this(serverClass, new DefaultNodeSelectionPolicy(), new ZkConfiguration());
  }
View Full Code Here

Examples of net.sf.katta.util.ZkConfiguration

  public Client(Class<? extends VersionedProtocol> serverClass, InteractionProtocol protocol) {
    this(serverClass, new DefaultNodeSelectionPolicy(), protocol, new ClientConfiguration());
  }

  public Client(Class<? extends VersionedProtocol> serverClass, final INodeSelectionPolicy nodeSelectionPolicy) {
    this(serverClass, nodeSelectionPolicy, new ZkConfiguration());
  }
View Full Code Here

Examples of net.sf.katta.util.ZkConfiguration

    LOG.info("~~~~~~~~~~~~~~~ starting zk system ~~~~~~~~~~~~~~~");
    String baseDir = "build/zkdata";
    FileUtil.deleteFolder(new File(baseDir));
    String dataDir = baseDir + "/data";
    String logDir = baseDir + "/log";
    _conf = new ZkConfiguration();
    _conf.setZKServers("localhost:" + PORT);
    _conf.setZKRootPath("/zk_testsystem");
    _zkServer = new ZkServer(dataDir, logDir, new DefaultNameSpaceImpl(_conf), PORT);
    _zkServer.start();
    LOG.info("~~~~~~~~~~~~~~~ zk system started ~~~~~~~~~~~~~~~");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.