Examples of CatalogService


Examples of com.ibatis.jpetstore.service.CatalogService

        catList.add("BIRDS");
        CATEGORY_LIST = Collections.unmodifiableList(catList);
    }

    public AccountBean() {
        this(new AccountService(), new CatalogService());
    }
View Full Code Here

Examples of com.ibatis.jpetstore.service.CatalogService

    private Cart cart = new Cart();
    private String workingItemId;
    private String pageDirection;

    public CartBean() {
        this(new CatalogService());
    }
View Full Code Here

Examples of com.ibatis.jpetstore.service.CatalogService

    private String itemId;
    private Item item;
    private PaginatedList itemList;

    public CatalogBean() {
        this(new CatalogService());
    }
View Full Code Here

Examples of com.ibatis.jpetstore.service.CatalogService

  private String itemId;
  private Item item;
  private PaginatedList itemList;

  public CatalogBean() {
    this(new CatalogService());
  }
View Full Code Here

Examples of com.ibatis.jpetstore.service.CatalogService

    catList.add("BIRDS");
    CATEGORY_LIST = Collections.unmodifiableList(catList);
  }

  public AccountBean() {
    this(new AccountService(), new CatalogService());
  }
View Full Code Here

Examples of com.ibatis.jpetstore.service.CatalogService

  private Cart cart = new Cart();
  private String workingItemId;
  private String pageDirection;

  public CartBean() {
    this (new CatalogService());
  }
View Full Code Here

Examples of org.apache.tajo.catalog.CatalogService

    if(query != null) {
      LOG.warn("Query already started");
      return;
    }

    CatalogService catalog = getQueryTaskContext().getQueryMasterContext().getWorkerContext().getCatalog();
    LogicalPlanner planner = new LogicalPlanner(catalog);
    LogicalOptimizer optimizer = new LogicalOptimizer();
    Expr expr;
    if (queryContext.isHiveQueryMode()) {
      HiveConverter hiveConverter = new HiveConverter();
View Full Code Here

Examples of org.apache.tajo.catalog.CatalogService

            DataChannel finalChannel = masterPlan.getChannel(castEvent.getExecutionBlockId(), nextBlock.getId());
            Path finalOutputDir = commitOutputData(query);
            TableDesc finalTableDesc = buildOrUpdateResultTableDesc(query, castEvent.getExecutionBlockId(), finalOutputDir);

            QueryContext queryContext = query.context.getQueryContext();
            CatalogService catalog = query.context.getQueryMasterContext().getWorkerContext().getCatalog();

            if (queryContext.hasOutputTable()) { // TRUE only if a query command is 'CREATE TABLE' OR 'INSERT INTO'
              if (queryContext.isOutputOverwrite()) { // TRUE only if a query is 'INSERT OVERWRITE INTO'
                catalog.deleteTable(finalOutputDir.getName());
              }
              catalog.addTable(finalTableDesc);
            }
            query.setResultDesc(finalTableDesc);
            query.finished(QueryState.QUERY_SUCCEEDED);
            query.eventHandler.handle(new QueryFinishEvent(query.getId()));
          }
View Full Code Here

Examples of org.apache.tajo.catalog.CatalogService

      TableDesc finalTableDesc = outputTableDesc;

      // If a query has a target table, a TableDesc is updated.
      if (queryContext.hasOutputTable()) { // CREATE TABLE or INSERT STATEMENT
        if (queryContext.isOutputOverwrite()) {
          CatalogService catalog = query.context.getQueryMasterContext().getWorkerContext().getCatalog();
          Preconditions.checkNotNull(catalog, "CatalogService is NULL");
          TableDesc updatingTable = catalog.getTableDesc(outputTableDesc.getName());
          updatingTable.getMeta().setStat(meta.getStat());
          finalTableDesc = updatingTable;
        }
      }
      return finalTableDesc;
View Full Code Here

Examples of org.apache.tajo.catalog.CatalogService

  public final void testInsertOverwrite() throws Exception {
    String tableName ="InsertOverwrite";
    ResultSet res = tpch.execute("create table " + tableName +" (col1 int8, col2 int4, col3 float4)");
    res.close();
    TajoTestingCluster cluster = tpch.getTestingCluster();
    CatalogService catalog = cluster.getMaster().getCatalog();
    assertTrue(catalog.existsTable(tableName));

    res = tpch.execute("insert overwrite into " + tableName
        + " select l_orderkey, l_partkey, l_quantity from lineitem");
    res.close();

    TableDesc desc = catalog.getTableDesc(tableName);
    assertEquals(5, desc.getMeta().getStat().getNumRows().intValue());
  }
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.