You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2022/09/12 10:14:22 UTC

[GitHub] [spark] MaxGekk commented on a diff in pull request #37834: [SPARK-40400][SQL] Pass error message parameters to exceptions as maps

MaxGekk commented on code in PR #37834:
URL: https://github.com/apache/spark/pull/37834#discussion_r968234159


##########
core/src/main/java/org/apache/spark/memory/SparkOutOfMemoryError.java:
##########
@@ -38,15 +40,15 @@ public SparkOutOfMemoryError(OutOfMemoryError e) {
         super(e.getMessage());
     }
 
-    public SparkOutOfMemoryError(String errorClass, String[] messageParameters) {
+    public SparkOutOfMemoryError(String errorClass, Map<String, String> messageParameters) {
         super(SparkThrowableHelper.getMessage(errorClass, null, messageParameters));
         this.errorClass = errorClass;
         this.messageParameters = messageParameters;
     }
 
     @Override
     public String[] getMessageParameters() {
-        return messageParameters;
+        return SparkThrowableHelper.getMessageParameters(errorClass, null, messageParameters);

Review Comment:
   This is tested by ShuffleExternalSorterSuite "nested spill should be no-op"



-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org