diff --git a/core/src/main/java/org/opensearch/sql/planner/Planner.java b/core/src/main/java/org/opensearch/sql/planner/Planner.java index 0d7725ca56..1397fa8a18 100644 --- a/core/src/main/java/org/opensearch/sql/planner/Planner.java +++ b/core/src/main/java/org/opensearch/sql/planner/Planner.java @@ -22,8 +22,8 @@ public class Planner { /** * Generate optimal physical plan for logical plan. If no table involved, translate logical plan - * to physical by default implementor. TODO: for now just delegate entire logical plan to storage - * engine. + * to physical by default implementor.
+ * TODO: for now just delegate entire logical plan to storage engine. * * @param plan logical plan * @return optimal physical plan diff --git a/core/src/main/java/org/opensearch/sql/planner/logical/LogicalValues.java b/core/src/main/java/org/opensearch/sql/planner/logical/LogicalValues.java index e586c391ff..95954fdec5 100644 --- a/core/src/main/java/org/opensearch/sql/planner/logical/LogicalValues.java +++ b/core/src/main/java/org/opensearch/sql/planner/logical/LogicalValues.java @@ -13,17 +13,20 @@ import org.opensearch.sql.expression.LiteralExpression; /** - * Logical operator which is a sequence of literal rows (like a relation). Basically, Values - * operator is used to create rows of constant literals "out of nothing" which is corresponding with - * VALUES clause in SQL. Mostly all rows must have the same number of literals and each column - * should have same type or can be converted implicitly. In particular, typical use cases include: - * 1. Project without relation involved. 2. Defining query or insertion without a relation. Take the + * Logical operator which is a sequence of literal rows (like a relation).
+ * Basically, Values operator is used to create rows of constant literals
+ * "out of nothing" which is corresponding with VALUES clause in SQL.
+ * Mostly all rows must have the same number of literals and each column should + * have same type or can be converted implicitly. In particular, typical use cases include: + *
    + *
  1. Project without relation involved.
  2. + *
  3. Defining query or insertion without a relation.
  4. + *
+ * Take the * following logical plan for example: * - *
- *  LogicalProject(expr=[log(2),true,1+2])
- *   |_ LogicalValues([[]])  #an empty row so that Project can evaluate its expressions in next()
- *  
+ * LogicalProject(expr=[log(2),true,1+2])
+ *   |_ LogicalValues([[]]) #an empty row so that Project can evaluate its expressions in next() */ @ToString @Getter diff --git a/core/src/main/java/org/opensearch/sql/planner/optimizer/LogicalPlanOptimizer.java b/core/src/main/java/org/opensearch/sql/planner/optimizer/LogicalPlanOptimizer.java index 7850b1259f..9b62bc96dd 100644 --- a/core/src/main/java/org/opensearch/sql/planner/optimizer/LogicalPlanOptimizer.java +++ b/core/src/main/java/org/opensearch/sql/planner/optimizer/LogicalPlanOptimizer.java @@ -19,9 +19,13 @@ import org.opensearch.sql.planner.optimizer.rule.write.CreateTableWriteBuilder; /** - * {@link LogicalPlan} Optimizer. The Optimizer will run in the TopDown manner. 1> Optimize the - * current node with all the rules. 2> Optimize the all the child nodes with all the rules. 3) In - * case the child node could change, Optimize the current node again. + * {@link LogicalPlan} Optimizer.
+ * The Optimizer will run in the TopDown manner.
+ *
    + *
  1. Optimize the current node with all the rules.
  2. + *
  3. Optimize the all the child nodes with all the rules.
  4. + *
  5. In case the child node could change, Optimize the current node again.
  6. + *
*/ public class LogicalPlanOptimizer { diff --git a/core/src/main/java/org/opensearch/sql/utils/OperatorUtils.java b/core/src/main/java/org/opensearch/sql/utils/OperatorUtils.java index 0e4bdcf202..d9ae0b4258 100644 --- a/core/src/main/java/org/opensearch/sql/utils/OperatorUtils.java +++ b/core/src/main/java/org/opensearch/sql/utils/OperatorUtils.java @@ -14,8 +14,9 @@ @UtilityClass public class OperatorUtils { /** - * Wildcard pattern matcher util. Percent (%) character for wildcard, Underscore (_) character for - * a single character match. + * Wildcard pattern matcher util.
+ * Percent (%) character for wildcard,
+ * Underscore (_) character for a single character match. * * @param pattern string pattern to match. * @return if text matches pattern returns true; else return false.