Search in sources :

Example 6 with CachingStatsProvider

use of com.facebook.presto.cost.CachingStatsProvider in project presto by prestodb.

the class RuleAssert method formatPlan.

private String formatPlan(PlanNode plan, TypeProvider types) {
    StatsProvider statsProvider = new CachingStatsProvider(statsCalculator, session, types);
    CostProvider costProvider = new CachingCostProvider(costCalculator, statsProvider, session);
    return inTransaction(session -> textLogicalPlan(translateExpressions(plan, types), types, metadata.getFunctionAndTypeManager(), StatsAndCosts.create(plan, statsProvider, costProvider), session, 2, false));
}
Also used : CachingStatsProvider(com.facebook.presto.cost.CachingStatsProvider) CachingStatsProvider(com.facebook.presto.cost.CachingStatsProvider) StatsProvider(com.facebook.presto.cost.StatsProvider) CachingCostProvider(com.facebook.presto.cost.CachingCostProvider) CachingCostProvider(com.facebook.presto.cost.CachingCostProvider) CostProvider(com.facebook.presto.cost.CostProvider)

Aggregations

CachingStatsProvider (com.facebook.presto.cost.CachingStatsProvider)6 CachingCostProvider (com.facebook.presto.cost.CachingCostProvider)5 StatsProvider (com.facebook.presto.cost.StatsProvider)5 CostProvider (com.facebook.presto.cost.CostProvider)4 PlanNodeIdAllocator (com.facebook.presto.spi.plan.PlanNodeIdAllocator)1 PlanVariableAllocator (com.facebook.presto.sql.planner.PlanVariableAllocator)1 JoinNode (com.facebook.presto.sql.planner.plan.JoinNode)1 SemiJoinNode (com.facebook.presto.sql.planner.plan.SemiJoinNode)1