MaxGekk commented on code in PR #40991:
URL: https://github.com/apache/spark/pull/40991#discussion_r1280961892
##########
common/utils/src/main/resources/error/error-classes.json:
##########
@@ -2423,6 +2423,12 @@
],
"sqlState" : "42883"
},
+ "RULE_ID_NOT_FOUND" : {
+ "message" : [
+ "Rule id not found for <ruleName>. Please modify RuleIdCollection.scala
if you are adding a new rule."
Review Comment:
Let's highlight the rule name in the error message as we do for other
parameters, and use the default quoting:
```suggestion
"Not found an id for the rule name \"<ruleName>\". Please modify
RuleIdCollection.scala if you are adding a new rule."
```
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/errors/QueryExecutionErrors.scala:
##########
@@ -1674,7 +1674,7 @@ private[sql] object QueryExecutionErrors extends
QueryErrorsBase {
def ruleIdNotFoundForRuleError(ruleName: String): Throwable = {
new SparkException(
- errorClass = "_LEGACY_ERROR_TEMP_2175",
+ errorClass = "RULE_ID_NOT_FOUND",
messageParameters = Map(
"ruleName" -> ruleName),
Review Comment:
```suggestion
messageParameters = Map("ruleName" -> ruleName),
```
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]