Examples of Args


Examples of org.apache.thrift.server.TServer.Args

            TServerSocket socket = new TServerSocket(new TServerSocket.ServerSocketTransportArgs().port(PORT));

            TTransportFactory factory = new TSaslServerTransport.Factory(
              WRAPPED_MECHANISM, SERVICE, HOST, WRAPPED_PROPS,
              new TestSaslCallbackHandler(PASSWORD));
            server = new TSimpleServer(new Args(socket).processor(processor).transportFactory(factory).protocolFactory(protoFactory));

            // Run it
            LOGGER.debug("Starting the server on port {}", PORT);
            server.serve();
          } catch (Exception e) {
View Full Code Here

Examples of org.apache.thrift.server.TServer.Args

    public static void StartsimpleServer(TimeService.Processor<TimeServiceHandler> processor) {
        try {
            TServerTransport serverTransport = new TServerSocket(9090);
            TServer server = new TSimpleServer(
                    new Args(serverTransport).processor(processor));

            // Use this for a multithreaded server
            // TServer server = new TThreadPoolServer(new
            // TThreadPoolServer.Args(serverTransport).processor(processor));
View Full Code Here

Examples of org.apache.thrift.server.TServer.Args

            TServerSocket socket = new TServerSocket(PORT);

            TTransportFactory factory = new TSaslServerTransport.Factory(
              WRAPPED_MECHANISM, SERVICE, HOST, WRAPPED_PROPS,
              new TestSaslCallbackHandler(PASSWORD));
            server = new TSimpleServer(new Args(socket).processor(processor).transportFactory(factory).protocolFactory(protoFactory));

            // Run it
            LOGGER.debug("Starting the server on port {}", PORT);
            server.serve();
          } catch (Exception e) {
View Full Code Here

Examples of org.apache.thrift.server.TThreadPoolServer.Args

    Factory proFactory = new TBinaryProtocol.Factory();

    chronosImplement = new ChronosImplement(properties, chronosServerWatcher);

    TProcessor processor = new ChronosService.Processor(chronosImplement);
    Args rpcArgs = new Args(serverTransport);
    rpcArgs.processor(processor);
    rpcArgs.protocolFactory(proFactory);
    rpcArgs.maxWorkerThreads(maxThread);
    thriftServer = new TThreadPoolServer(rpcArgs);
  }
View Full Code Here

Examples of org.apache.thrift.server.TThreadedSelectorServer.Args

import org.apache.thrift.server.TThreadedSelectorServer.Args;
import org.apache.thrift.transport.TNonblockingServerSocket;

public class TestThreadedSelectorServer extends TestNonblockingServer {
  protected TServer getServer(TProcessor processor, TNonblockingServerSocket socket, TProtocolFactory protoFactory) {
    return new TThreadedSelectorServer(new Args(socket).processor(processor).protocolFactory(protoFactory));
  }
View Full Code Here

Examples of org.apache.thrift.server.TThreadedSelectorServer.Args

    log.debug("Thrift server started in {}", addr);

    // TODO default selectorThreads is 2. Test if this is enough under load,
    // or we would need more selector threads.
    Args args = new Args(transport);
    args.executorService(executorService.getExecutor())
        .processor(processor);

    server = new NonBlockingTThreadedSelectorServer(args);
    server.serve();
  }
View Full Code Here

Examples of org.neo4j.helpers.Args

    private static final String FULL = "full";
    public static final String DEFAULT_SCHEME = "simple";

    public static void main( String[] args )
    {
        Args arguments = new Args( args );

        checkArguments( arguments );

        boolean full = arguments.has( FULL );
        String from = arguments.get( FROM, null );
        String to = arguments.get( TO, null );
        URI backupURI = null;
        try
        {
            backupURI = new URI( from );
        }
View Full Code Here

Examples of org.neo4j.helpers.Args

    public static void main( String[] strArgs ) throws Exception
    {
        try
        {
            Args args = new Args( strArgs );

            //
            // 1. ARGUMENT HANDLING
            //

            System.setProperty( "org.neo4j.webadmin.developmentmode",
                    args.get( "development", "false" ) );
            System.setProperty( "org.neo4j.graphdb.location",
                    args.get( "dbPath", "neo4j-rest-db" ) );
            System.setProperty( "org.neo4j.webadmin.rrdb.location",
                    args.get( "rrdbPath", "neo4j-rrdb" ) );

            int restPort = args.getNumber( "restPort",
                    WebServerFactory.DEFAULT_PORT ).intValue();
            int adminPort = args.getNumber( "adminPort",
                    AdminServer.DEFAULT_PORT ).intValue();
            String db_location = System.getProperty( "org.neo4j.graphdb.location");
            System.out.println("graphdb-location: " + db_location);

            String webRoot = args.get( "webRoot",
                    AdminServer.DEFAULT_STATIC_PATH );

            //
            // 2. START SERVERS
            //
View Full Code Here

Examples of org.vertx.java.platform.impl.Args

  private Starter(String[] sargs) {
    if (sargs.length < 1) {
      displaySyntax();
    } else {
      String command = sargs[0].toLowerCase();
      Args args = new Args(sargs);
      if ("version".equals(command)) {
        log.info(getVersion());
      } else {
        if (sargs.length < 2) {
          displaySyntax();
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.