Class DruidRels

java.lang.Object
org.apache.druid.sql.calcite.rel.DruidRels

public class DruidRels extends Object
  • Constructor Details

    • DruidRels

      public DruidRels()
  • Method Details

    • druidTableIfLeafRel

      public static Optional<DruidTable> druidTableIfLeafRel(DruidRel<?> druidRel)
      Returns the DataSource involved in a leaf query of class DruidQueryRel.
    • isScanOrMapping

      public static boolean isScanOrMapping(DruidRel<?> druidRel, boolean canBeJoinOrUnion)
      Check if a druidRel is a simple table scan, or a projection that merely remaps columns without transforming them. Like isScanOrProject(org.apache.druid.sql.calcite.rel.DruidRel<?>, boolean) but more restrictive: only remappings are allowed.
      Parameters:
      druidRel - the rel to check
      canBeJoinOrUnion - consider a DruidJoinQueryRel or DruidUnionDataSourceRel as possible scans-and-mappings too.
    • isScanOrProject

      public static boolean isScanOrProject(DruidRel<?> druidRel, boolean canBeJoinOrUnion)
      Check if a druidRel is a simple table scan or a scan + projection.
      Parameters:
      druidRel - the rel to check
      canBeJoinOrUnion - consider a DruidJoinQueryRel or DruidUnionDataSourceRel as possible scans-and-mappings too.
    • dataSourceSignature

      public static RowSignature dataSourceSignature(DruidRel<?> druidRel)
      Returns the signature of the datasource of a DruidRel. This is not the signature of the DruidRel itself: in particular, it ignores any operations that are layered on top of the datasource.