use of com.apple.foundationdb.record.query.plan.plans.RecordQueryInJoinPlan in project fdb-record-layer by FoundationDB.
the class PushInJoinThroughFetchRule method onMatch.
@Override
public void onMatch(@Nonnull PlannerRuleCall call) {
final PlannerBindings bindings = call.getBindings();
final RecordQueryInJoinPlan inJoinPlan = bindings.get(getMatcher());
final RecordQueryFetchFromPartialRecordPlan fetchPlan = bindings.get(fetchPlanMatcher);
final RecordQueryPlan innerPlan = bindings.get(innerPlanMatcher);
final RecordQueryPlanWithChild pushedInJoinPlan = inJoinPlan.withChild(innerPlan);
final var newFetchPlan = new RecordQueryFetchFromPartialRecordPlan(pushedInJoinPlan, fetchPlan.getPushValueFunction());
call.yield(call.ref(newFetchPlan));
}
Aggregations