Package org.apache.calcite.rel.metadata
Interface BuiltInMetadata.Memory
- All Superinterfaces:
Metadata
- Enclosing class:
BuiltInMetadata
Metadata about the memory use of an operator.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
Handler API. -
Field Summary
-
Method Summary
Modifier and TypeMethodDescription@Nullable Double
Returns the cumulative amount of memory, in bytes, required by the physical operator implementing this relational expression, and all other operators within the same phase, across all splits.@Nullable Double
Returns the expected cumulative amount of memory, in bytes, required by the physical operator implementing this relational expression, and all operators within the same phase, within each split.@Nullable Double
memory()
Returns the expected amount of memory, in bytes, required by a physical operator implementing this relational expression, across all splits.
-
Field Details
-
DEF
-
-
Method Details
-
memory
@Nullable Double memory()Returns the expected amount of memory, in bytes, required by a physical operator implementing this relational expression, across all splits.How much memory is used depends very much on the algorithm; for example, an implementation of
Aggregate
that loads all data into a hash table requires approximatelyrowCount * averageRowSize
bytes, whereas an implementation that assumes that the input is sorted requires onlyaverageRowSize
bytes to maintain a single accumulator for each aggregate function. -
cumulativeMemoryWithinPhase
@Nullable Double cumulativeMemoryWithinPhase()Returns the cumulative amount of memory, in bytes, required by the physical operator implementing this relational expression, and all other operators within the same phase, across all splits.- See Also:
-
cumulativeMemoryWithinPhaseSplit
@Nullable Double cumulativeMemoryWithinPhaseSplit()Returns the expected cumulative amount of memory, in bytes, required by the physical operator implementing this relational expression, and all operators within the same phase, within each split.Basic formula:
cumulativeMemoryWithinPhaseSplit = cumulativeMemoryWithinPhase / Parallelism.splitCount
-