Class RewriteSpatialPartitioningAggregation
- java.lang.Object
-
- io.prestosql.sql.planner.iterative.rule.RewriteSpatialPartitioningAggregation
-
- All Implemented Interfaces:
Rule<AggregationNode>
public class RewriteSpatialPartitioningAggregation extends Object implements Rule<AggregationNode>
Re-writes spatial_partitioning(geometry) aggregations into spatial_partitioning(envelope, partition_count) on top of ST_Envelope(geometry) projection, e.g.- Aggregation: spatial_partitioning(geometry) - source
becomes- Aggregation: spatial_partitioning(envelope, partition_count) - Project: envelope := ST_Envelope(geometry) - source
, where partition_count is the value of session property hash_partition_count
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface io.prestosql.sql.planner.iterative.Rule
Rule.Context, Rule.Result
-
-
Constructor Summary
Constructors Constructor Description RewriteSpatialPartitioningAggregation(Metadata metadata)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Rule.Result
apply(AggregationNode node, Captures captures, Rule.Context context)
Pattern<AggregationNode>
getPattern()
Returns a pattern to which plan nodes this rule applies.
-
-
-
Constructor Detail
-
RewriteSpatialPartitioningAggregation
public RewriteSpatialPartitioningAggregation(Metadata metadata)
-
-
Method Detail
-
getPattern
public Pattern<AggregationNode> getPattern()
Description copied from interface:Rule
Returns a pattern to which plan nodes this rule applies.- Specified by:
getPattern
in interfaceRule<AggregationNode>
-
apply
public Rule.Result apply(AggregationNode node, Captures captures, Rule.Context context)
- Specified by:
apply
in interfaceRule<AggregationNode>
-
-