Class PruneLeftJoinOnNullMatchingField


public class PruneLeftJoinOnNullMatchingField extends OptimizerRules.ParameterizedOptimizerRule<Join,LogicalOptimizerContext>
The rule checks if the join's performed on a field which is aliased to null (in type or value); if that's the case, it prunes the join, replacing it with an Eval - returning aliases to null for all the fields added in by the right side of the Join - plus a Project on top of it. The rule can apply on the coordinator already, but it's more likely to be effective on the data nodes, where null aliasing is inserted due to locally missing fields. This rule relies on that behavior -- see ReplaceFieldWithConstantOrNull.