twalthr commented on a change in pull request #17931:
URL: https://github.com/apache/flink/pull/17931#discussion_r759087903



##########
File path: 
flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/delegation/ExpressionParser.java
##########
@@ -16,27 +16,24 @@
  * limitations under the License.
  */
 
-package org.apache.flink.table.expressions;
+package org.apache.flink.table.delegation;
 
 import org.apache.flink.annotation.Internal;
-import org.apache.flink.table.delegation.PlannerExpressionParser;
+import org.apache.flink.table.expressions.Expression;
 
 import java.util.List;
 
 /**
- * Parser for expressions inside a String. This parses exactly the same 
expressions that would be
- * accepted by the Scala Expression DSL.
- *
- * <p>{@link ExpressionParser} use {@link PlannerExpressionParser} to parse 
expressions.
+ * {@link Expression} parser used by Table API to parse strings in AST 
expression. This parses
+ * exactly the same expressions that would be accepted by the Scala Expression 
DSL.
  */
 @Internal
-public final class ExpressionParser {
+public interface ExpressionParser {

Review comment:
       deprecate the class

##########
File path: 
flink-table/flink-table-planner/src/main/java/org/apache/flink/table/planner/delegation/ParserImpl.java
##########
@@ -64,6 +65,7 @@
     private final Supplier<CalciteParser> calciteParserSupplier;
     private final SqlExprToRexConverterFactory sqlExprToRexConverterFactory;
     private static final ExtendedParser EXTENDED_PARSER = 
ExtendedParser.INSTANCE;
+    private static final ExpressionParserImpl expressionParser = new 
ExpressionParserImpl();

Review comment:
       why this change? this deprecated parser has nothing to do with the SQL 
parser.

##########
File path: 
flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/delegation/ExpressionParserFactory.java
##########
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.table.delegation;
+
+import org.apache.flink.annotation.Internal;
+import org.apache.flink.table.factories.Factory;
+import org.apache.flink.table.factories.FactoryUtil;
+
+/** Factory for {@link ExpressionParser}. */
+@Internal
+public interface ExpressionParserFactory extends Factory {

Review comment:
       deprecate the class




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to