Package com.odiago.flumebase.exec.local

Examples of com.odiago.flumebase.exec.local.LocalEnvironment


    getSymbolTable().addSymbol(rightStream);

    getConf().set(SelectStmt.CLIENT_SELECT_TARGET_KEY, "testJoin");

    // With all configuration complete, connect to the environment.
    LocalEnvironment env = getEnvironment();
    env.connect();

    // Run the query.
    QuerySubmitResponse response = env.submitQuery(query, getQueryOpts());
    FlowId id = response.getFlowId();
    assertNotNull(response.getMessage(), id);
    joinFlow(id);

    // Examine the response records.
View Full Code Here


    getSymbolTable().addSymbol(stream);

    getConf().set(SelectStmt.CLIENT_SELECT_TARGET_KEY, "testGroupBy");

    // With all configuration complete, connect to the environment.
    LocalEnvironment env = getEnvironment();
    env.connect();

    // Run the query.
    QuerySubmitResponse response = env.submitQuery(query, getQueryOpts());
    FlowId id = response.getFlowId();
    if (expectFailure) {
      if (null == id) {
        // Our work here is done: we expected submission of the query to fail,
        // and it did. Return null for results.
View Full Code Here

  private void connect(String host) {
    disconnect(); // Always disconnect from the current environment before reconnecting.
    try {
      if ("local".equals(host)) {
        LOG.info("Connecting to local environment.");
        mExecEnv = new LocalEnvironment(mConf);
      } else if ("none".equals(host)) {
        mExecEnv = new DummyExecEnv();
      } else {
        int portIndex = host.indexOf(':');
        int port = mConf.getInt(ServerMain.THRIFT_SERVER_PORT_KEY,
View Full Code Here

    getSymbolTable().addSymbol(stream);

    getConf().set(SelectStmt.CLIENT_SELECT_TARGET_KEY, "testThroughput");

    // With all configuration complete, connect to the environment.
    LocalEnvironment env = getEnvironment();
    env.connect();

    long startTimestamp = System.currentTimeMillis();

    // Run the query.
    QuerySubmitResponse response = env.submitQuery(query, getQueryOpts());
    FlowId id = response.getFlowId();
    assertNotNull(response.getMessage(), id);
    joinFlow(id);

    long stopTimestamp = System.currentTimeMillis();
View Full Code Here

  public void setUp() {
    mSymbolTable = new HashSymbolTable(new BuiltInSymbolTable());
    mConf = new Configuration();
    mOutputs = Collections.synchronizedMap(new HashMap<String, MemoryOutputElement>());
    mFlumeConfig = new EmbeddedFlumeConfig(mConf);
    mEnvironment = new LocalEnvironment(mConf, mSymbolTable, mOutputs, mFlumeConfig);
  }
View Full Code Here

        strcatFunc.getArgumentTypes(), strcatFunc.getVarArgTypes()));

    getConf().set(SelectStmt.CLIENT_SELECT_TARGET_KEY, "testSelect");

    // With all configuration complete, connect to the environment.
    LocalEnvironment env = getEnvironment();
    env.connect();

    // Run the query.
    LOG.debug("Actually submitting to running environment");
    QuerySubmitResponse response = env.submitQuery(query, getQueryOpts());
    FlowId id = response.getFlowId();
    assertNotNull(response.getMessage(), id);
    joinFlow(id);
    LOG.debug("Flow runtime complete");
View Full Code Here

TOP

Related Classes of com.odiago.flumebase.exec.local.LocalEnvironment

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.