@@ -34,7 +34,7 @@ use datafusion::physical_plan::expressions::{
3434use datafusion:: physical_plan:: expressions:: { CastExpr , TryCastExpr } ;
3535use datafusion:: physical_plan:: filter:: FilterExec ;
3636use datafusion:: physical_plan:: hash_aggregate:: AggregateMode ;
37- use datafusion:: physical_plan:: hash_join:: HashJoinExec ;
37+ use datafusion:: physical_plan:: hash_join:: { HashJoinExec , PartitionMode } ;
3838use datafusion:: physical_plan:: hash_utils:: JoinType ;
3939use datafusion:: physical_plan:: limit:: { GlobalLimitExec , LocalLimitExec } ;
4040use datafusion:: physical_plan:: parquet:: ParquetExec ;
@@ -143,13 +143,18 @@ impl TryInto<protobuf::PhysicalPlanNode> for Arc<dyn ExecutionPlan> {
143143 JoinType :: Semi => protobuf:: JoinType :: Semi ,
144144 JoinType :: Anti => protobuf:: JoinType :: Anti ,
145145 } ;
146+ let partition_mode = match exec. partition_mode ( ) {
147+ PartitionMode :: CollectLeft => protobuf:: PartitionMode :: CollectLeft ,
148+ PartitionMode :: Partitioned => protobuf:: PartitionMode :: Partitioned ,
149+ } ;
146150 Ok ( protobuf:: PhysicalPlanNode {
147151 physical_plan_type : Some ( PhysicalPlanType :: HashJoin ( Box :: new (
148152 protobuf:: HashJoinExecNode {
149153 left : Some ( Box :: new ( left) ) ,
150154 right : Some ( Box :: new ( right) ) ,
151155 on,
152156 join_type : join_type. into ( ) ,
157+ partition_mode : partition_mode. into ( ) ,
153158 } ,
154159 ) ) ) ,
155160 } )
0 commit comments