Class PartitionResult
- java.lang.Object
-
- org.apache.ignite.internal.sql.optimizer.affinity.PartitionResult
-
public class PartitionResult extends Object
Partition extraction result.
-
-
Constructor Summary
Constructors Constructor Description PartitionResult(PartitionNode tree, AffinityTopologyVersion topVer, String cacheName, int partsCnt)Constructor.PartitionResult(PartitionNode tree, PartitionTableAffinityDescriptor aff, AffinityTopologyVersion topVer)Constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description PartitionTableAffinityDescriptoraffinity()StringcacheName()static int[]calculatePartitions(int[] explicitParts, PartitionResult derivedParts, Object[] args)Calculate partitions for the query.booleanisClientPartitionAwarenessApplicable()intpartitionsCount()AffinityTopologyVersiontopologyVersion()StringtoString()PartitionNodetree()Tree.
-
-
-
Constructor Detail
-
PartitionResult
public PartitionResult(PartitionNode tree, PartitionTableAffinityDescriptor aff, AffinityTopologyVersion topVer)
Constructor.- Parameters:
tree- Tree.aff- Affinity function.
-
PartitionResult
public PartitionResult(PartitionNode tree, AffinityTopologyVersion topVer, String cacheName, int partsCnt)
Constructor.- Parameters:
tree- Tree.topVer- Affinity topology version.cacheName- Cache name.partsCnt- Partitions count.
-
-
Method Detail
-
tree
public PartitionNode tree()
Tree.
-
affinity
public PartitionTableAffinityDescriptor affinity()
- Returns:
- Affinity function.
-
calculatePartitions
public static int[] calculatePartitions(int[] explicitParts, PartitionResult derivedParts, Object[] args)Calculate partitions for the query.- Parameters:
explicitParts- Explicit partitions provided in SqlFieldsQuery.partitions property.derivedParts- Derived partitions found during partition pruning.args- Arguments.- Returns:
- Calculated partitions or
nullif failed to calculate and there should be a broadcast.
-
topologyVersion
public AffinityTopologyVersion topologyVersion()
- Returns:
- Affinity topology version. This method is intended to be used within the Jdbc thin client.
-
cacheName
public String cacheName()
- Returns:
- Cache name. This method is intended to be used within the Jdbc thin client.
-
partitionsCount
public int partitionsCount()
- Returns:
- Partitions count. This method is intended to be used within the Jdbc thin client.
-
isClientPartitionAwarenessApplicable
public boolean isClientPartitionAwarenessApplicable()
- Returns:
- True if applicable to jdbc thin client side partition awareness: 1. Rendezvous affinity function without map filters was used; 2. Partition result tree neither PartitoinAllNode nor PartitionNoneNode;
-
-