Examples of analyzePredicate()


Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

   * @return DecomposedPredicate containing translated search conditions the analyzer can support.
   */
  public DecomposedPredicate decompose(Configuration conf, ExprNodeDesc desc) {
    IndexPredicateAnalyzer analyzer = newAnalyzer(conf);
    List<IndexSearchCondition> sConditions = new ArrayList<IndexSearchCondition>();
    ExprNodeDesc residualPredicate = analyzer.analyzePredicate(desc, sConditions);

    if (sConditions.size() == 0) {
      if (log.isInfoEnabled())
        log.info("nothing to decompose. Returning");
      return null;
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

    IndexPredicateAnalyzer analyzer = HiveHBaseTableInputFormat.newIndexPredicateAnalyzer(
        keyMapping.columnName, keyMapping.isComparable(),
        tsMapping == null ? null : tsMapping.columnName);
    List<IndexSearchCondition> conditions = new ArrayList<IndexSearchCondition>();
    ExprNodeGenericFuncDesc residualPredicate =
        (ExprNodeGenericFuncDesc)analyzer.analyzePredicate(predicate, conditions);

    for (List<IndexSearchCondition> searchConditions:
        HiveHBaseInputFormatUtil.decompose(conditions).values()) {
      int scSize = searchConditions.size();
      if (scSize < 1 || 2 < scSize) {
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

    DecomposedPredicate decomposed = new DecomposedPredicate();

    List<IndexSearchCondition> searchConditions = new ArrayList<IndexSearchCondition>();
    decomposed.residualPredicate =
        (ExprNodeGenericFuncDesc)analyzer.analyzePredicate(predicate, searchConditions);
    if (!searchConditions.isEmpty()) {
      decomposed.pushedPredicate = analyzer.translateSearchConditions(searchConditions);
      try {
        decomposed.pushedPredicateObject = setupFilter(keyColName, searchConditions);
      } catch (IOException e) {
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

  private DecomposedPredicate decomposePredicate(ExprNodeDesc predicate, Index index,
      Set<Partition> queryPartitions) {
    IndexPredicateAnalyzer analyzer = getIndexPredicateAnalyzer(index, queryPartitions);
    List<IndexSearchCondition> searchConditions = new ArrayList<IndexSearchCondition>();
    // split predicate into pushed (what we can handle), and residual (what we can't handle)
    ExprNodeDesc residualPredicate = analyzer.analyzePredicate(predicate, searchConditions);

    if (searchConditions.size() == 0) {
      return null;
    }
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

  private DecomposedPredicate decomposePredicate(ExprNodeDesc predicate, Index index,
      Set<Partition> queryPartitions) {
    IndexPredicateAnalyzer analyzer = getIndexPredicateAnalyzer(index, queryPartitions);
    List<IndexSearchCondition> searchConditions = new ArrayList<IndexSearchCondition>();
    // split predicate into pushed (what we can handle), and residual (what we can't handle)
    ExprNodeGenericFuncDesc residualPredicate = (ExprNodeGenericFuncDesc)analyzer.
      analyzePredicate(predicate, searchConditions);

    if (searchConditions.size() == 0) {
      return null;
    }
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

    Map<Index, ExprNodeDesc> indexPredicates = new HashMap<Index, ExprNodeDesc>();
    // compute overall residual
    IndexPredicateAnalyzer analyzer = getIndexPredicateAnalyzer(indexes, queryContext.getQueryPartitions());
    List<IndexSearchCondition> searchConditions = new ArrayList<IndexSearchCondition>();
    ExprNodeDesc residualPredicate = analyzer.analyzePredicate(predicate, searchConditions);
    // pass residual predicate back out for further processing
    queryContext.setResidualPredicate(residualPredicate);

    if (searchConditions.size() == 0) {
      return null;
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

      analyzer = getIndexPredicateAnalyzer(in, queryContext.getQueryPartitions());
      searchConditions = new ArrayList<IndexSearchCondition>();
      // split predicate into pushed (what we can handle), and residual (what we can't handle)
      // pushed predicate from translateSearchConditions is stored for the current index
      // This ensures that we apply all possible predicates to each index
      analyzer.analyzePredicate(predicate, searchConditions);
      if (searchConditions.size() == 0) {
        indexPredicates.put(index, null);
      } else {
        indexPredicates.put(index, analyzer.translateSearchConditions(searchConditions));
      }
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

    Map<Index, ExprNodeDesc> indexPredicates = new HashMap<Index, ExprNodeDesc>();
    // compute overall residual
    IndexPredicateAnalyzer analyzer = getIndexPredicateAnalyzer(indexes, queryContext.getQueryPartitions());
    List<IndexSearchCondition> searchConditions = new ArrayList<IndexSearchCondition>();
    ExprNodeDesc residualPredicate = analyzer.analyzePredicate(predicate, searchConditions);
    // pass residual predicate back out for further processing
    queryContext.setResidualPredicate(residualPredicate);

    if (searchConditions.size() == 0) {
      return null;
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

      analyzer = getIndexPredicateAnalyzer(in, queryContext.getQueryPartitions());
      searchConditions = new ArrayList<IndexSearchCondition>();
      // split predicate into pushed (what we can handle), and residual (what we can't handle)
      // pushed predicate from translateSearchConditions is stored for the current index
      // This ensures that we apply all possible predicates to each index
      analyzer.analyzePredicate(predicate, searchConditions);
      if (searchConditions.size() == 0) {
        indexPredicates.put(index, null);
      } else {
        indexPredicates.put(index, analyzer.translateSearchConditions(searchConditions));
      }
View Full Code Here

Examples of org.apache.hadoop.hive.ql.index.IndexPredicateAnalyzer.analyzePredicate()

  private DecomposedPredicate decomposePredicate(ExprNodeDesc predicate, Index index,
      Set<Partition> queryPartitions) {
    IndexPredicateAnalyzer analyzer = getIndexPredicateAnalyzer(index, queryPartitions);
    List<IndexSearchCondition> searchConditions = new ArrayList<IndexSearchCondition>();
    // split predicate into pushed (what we can handle), and residual (what we can't handle)
    ExprNodeGenericFuncDesc residualPredicate = (ExprNodeGenericFuncDesc)analyzer.
      analyzePredicate(predicate, searchConditions);

    if (searchConditions.size() == 0) {
      return null;
    }
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.