Example #1
0
bool EqualJoin::isHashOnLeftKey(const Partitioner& part,const Attribute& key)const{
	if(part.getPartitionFashion()!=PartitionFunction::hash_f)
		return false;
	for(unsigned i=0;i<joinkey_pair_list_.size();i++){

	}
	return part.getPartitionKey()==key;
}
DataflowPartitioningDescriptor::DataflowPartitioningDescriptor(const Partitioner& partitioner){
	partition_function_=partitioner.getPartitionFunction();
	partition_key_=partitioner.getPartitionKey();
	for(unsigned i=0;i<partitioner.getNumberOfPartitions();i++){
		DataflowPartition dataflow_partition;
		dataflow_partition.datasize_=partitioner.getPartitionDataSize(i);
		dataflow_partition.location_=partitioner.getPartitionLocation(i);
		dataflow_partition.partition_id_=i;
		partition_list_.push_back(dataflow_partition);
	}
}
Example #3
0
PlanPartitioner::PlanPartitioner(const Partitioner& partitioner) {
  partition_func_ = partitioner.getPartitionFunction();
  partition_key_ = partitioner.getPartitionKey();
  for (unsigned i = 0; i < partitioner.getNumberOfPartitions(); i++) {
    PlanPartitionInfo plan_partition_info;
    plan_partition_info.cardinality_ = partitioner.getPartitionCardinality(i);
    plan_partition_info.location_ = partitioner.getPartitionLocation(i);
    plan_partition_info.partition_id_ = i;
    partition_list_.push_back(plan_partition_info);
  }
}