Package org.apache.accumulo.server.util.TServerUtils

Examples of org.apache.accumulo.server.util.TServerUtils.ServerPort


    Instance instance = HdfsZooInstance.getInstance();
   
    TransactionWatcher watcher = new TransactionWatcher();
    final ThriftClientHandler tch = new ThriftClientHandler(instance, watcher);
    Processor<Iface> processor = new Processor<Iface>(tch);
    ServerPort serverPort = TServerUtils.startTServer(port, processor, "ZombieTServer", "walking dead", 2, 1000, 10*1024*1024);
   
    InetSocketAddress addr = new InetSocketAddress(InetAddress.getLocalHost(), serverPort.port);
    String addressString = AddressUtil.toString(addr);
    String zPath = ZooUtil.getRoot(instance) + Constants.ZTSERVERS + "/" + addressString;
    ZooReaderWriter zoo = ZooReaderWriter.getInstance();
View Full Code Here


    entry.logSet = logSet;
    MetadataTable.addLogEntry(SecurityConstants.getSystemCredentials(), entry, getLock());
  }
 
  private int startServer(AccumuloConfiguration conf, Property portHint, TProcessor processor, String threadName) throws UnknownHostException {
    ServerPort sp = TServerUtils.startServer(conf, portHint, processor, this.getClass().getSimpleName(), threadName, Property.TSERV_PORTSEARCH,
        Property.TSERV_MINTHREADS, Property.TSERV_THREADCHECK, Property.GENERAL_MAX_MESSAGE_SIZE);
    this.server = sp.server;
    return sp.port;
  }
View Full Code Here

    } catch (InterruptedException e) {
      throw new IOException(e);
    }

    Processor<Iface> processor = new Processor<Iface>(TraceWrap.service(new MasterClientServiceHandler()));
    ServerPort serverPort = TServerUtils.startServer(getSystemConfiguration(), Property.MASTER_CLIENTPORT, processor, "Master",
        "Master Client Service Handler", null, Property.MASTER_MINTHREADS, Property.MASTER_THREADCHECK, Property.GENERAL_MAX_MESSAGE_SIZE);
    clientService = serverPort.server;
    InetSocketAddress sock = org.apache.accumulo.core.util.AddressUtil.parseAddress(hostname, serverPort.port);
    String address = org.apache.accumulo.core.util.AddressUtil.toString(sock);
    log.info("Setting master lock data to " + address);
View Full Code Here

      }
    };
    writer = (MutationLogger.Iface) Proxy.newProxyInstance(MutationLogger.Iface.class.getClassLoader(), new Class[] {MutationLogger.Iface.class}, h);
    // Create the thrift-based logging service
    MutationLogger.Processor processor = new MutationLogger.Processor(TraceWrap.service(this));
    ServerPort sp = TServerUtils.startServer(Property.LOGGER_PORT, processor, this.getClass().getSimpleName(), "Logger Client Service Handler",
        Property.LOGGER_PORTSEARCH, Property.LOGGER_MINTHREADS, Property.LOGGER_THREADCHECK);
    service = sp.server;
    InetSocketAddress address = new InetSocketAddress(Accumulo.getLocalAddress(args), sp.port);
    addressString = AddressUtil.toString(address);
    registerInZooKeeper(Constants.ZLOGGERS);
View Full Code Here

    }
    MetadataTable.addLogEntries(SecurityConstants.getSystemCredentials(), entries, getLock());
  }

  private int startServer(Property portHint, TProcessor processor, String threadName) throws UnknownHostException {
    ServerPort sp = TServerUtils.startServer(portHint, processor, this.getClass().getSimpleName(), threadName, Property.TSERV_PORTSEARCH,
        Property.TSERV_MINTHREADS, Property.TSERV_THREADCHECK);
    this.server = sp.server;
    return sp.port;
  }
View Full Code Here

    Instance instance = HdfsZooInstance.getInstance();
   
    TransactionWatcher watcher = new TransactionWatcher();
    final ThriftClientHandler tch = new ThriftClientHandler(instance, watcher);
    Processor<Iface> processor = new Processor<Iface>(tch);
    ServerPort serverPort = TServerUtils.startTServer(port, processor, "ZombieTServer", "walking dead", 2, 1000, 10*1024*1024);
   
    InetSocketAddress addr = new InetSocketAddress(InetAddress.getLocalHost(), serverPort.port);
    String addressString = AddressUtil.toString(addr);
    String zPath = ZooUtil.getRoot(instance) + Constants.ZTSERVERS + "/" + addressString;
    ZooReaderWriter zoo = ZooReaderWriter.getInstance();
View Full Code Here

    entry.logSet = logSet;
    MetadataTable.addLogEntry(SecurityConstants.getSystemCredentials(), entry, getLock());
  }
 
  private int startServer(AccumuloConfiguration conf, Property portHint, TProcessor processor, String threadName) throws UnknownHostException {
    ServerPort sp = TServerUtils.startServer(conf, portHint, processor, this.getClass().getSimpleName(), threadName, Property.TSERV_PORTSEARCH,
        Property.TSERV_MINTHREADS, Property.TSERV_THREADCHECK, Property.GENERAL_MAX_MESSAGE_SIZE);
    this.server = sp.server;
    return sp.port;
  }
View Full Code Here

    }
    MetadataTable.addLogEntries(SecurityConstants.getSystemCredentials(), entries, getLock());
  }
 
  private int startServer(Property portHint, TProcessor processor, String threadName) throws UnknownHostException {
    ServerPort sp = TServerUtils.startServer(portHint, processor, this.getClass().getSimpleName(), threadName, Property.TSERV_PORTSEARCH,
        Property.TSERV_MINTHREADS, Property.TSERV_THREADCHECK);
    this.server = sp.server;
    return sp.port;
  }
View Full Code Here

      }
    };
    writer = (MutationLogger.Iface) Proxy.newProxyInstance(MutationLogger.Iface.class.getClassLoader(), new Class[] {MutationLogger.Iface.class}, h);
    // Create the thrift-based logging service
    MutationLogger.Processor processor = new MutationLogger.Processor(TraceWrap.service(this));
    ServerPort sp = TServerUtils.startServer(Property.LOGGER_PORT, processor, this.getClass().getSimpleName(), "Logger Client Service Handler",
        Property.LOGGER_PORTSEARCH, Property.LOGGER_MINTHREADS, Property.LOGGER_THREADCHECK);
    service = sp.server;
    InetSocketAddress address = new InetSocketAddress(Accumulo.getLocalAddress(args), sp.port);
    addressString = AddressUtil.toString(address);
    registerInZooKeeper(Constants.ZLOGGERS);
View Full Code Here

    }
    MetadataTable.addLogEntries(SecurityConstants.systemCredentials, entries, getLock());
  }
 
  private int startServer(Property portHint, TProcessor processor, String threadName) throws UnknownHostException {
    ServerPort sp = TServerUtils.startServer(portHint, processor, this.getClass().getSimpleName(), threadName, AccumuloConfiguration.getSystemConfiguration()
        .getBoolean(Property.TSERV_PORTSEARCH));
    this.server = sp.server;
    return sp.port;
  }
View Full Code Here

TOP

Related Classes of org.apache.accumulo.server.util.TServerUtils.ServerPort

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.